<?php
class JhDateTime extends DateTime {}
$date1 = new JhDateTime("10 September 2014");
$date2 = new JhDateTime("17 September 2014");
$period = new \DatePeriod(
$date1 ,
new \DateInterval("P1M"),
$date2
);
foreach($period as $date) {
var_dump(get_class($date));
}
Warning: Unexpected character in input: '\' (ASCII=92) state=1 in /in/DQShV on line 11
Warning: Unexpected character in input: '\' (ASCII=92) state=1 in /in/DQShV on line 13
Fatal error: Class 'DatePeriod' not found in /in/DQShV on line 11
Process exited with code 255.
Output for 5.0.0 - 5.0.5, 5.1.0 - 5.1.6
Warning: Unexpected character in input: '\' (ASCII=92) state=1 in /in/DQShV on line 11
Warning: Unexpected character in input: '\' (ASCII=92) state=1 in /in/DQShV on line 13
Fatal error: Class 'DateTime' not found in /in/DQShV on line 4
Process exited with code 255.
Output for 4.3.2 - 4.3.11, 4.4.0 - 4.4.9
Warning: Unexpected character in input: '\' (ASCII=92) state=1 in /in/DQShV on line 11
Warning: Unexpected character in input: '\' (ASCII=92) state=1 in /in/DQShV on line 13
Fatal error: Class jhdatetime: Cannot inherit from undefined class datetime in /in/DQShV on line 4
Process exited with code 255.
Output for 4.3.0 - 4.3.1
Warning: Unexpected character in input: '\' (ASCII=92) state=1 in /in/DQShV on line 11
Warning: Unexpected character in input: '\' (ASCII=92) state=1 in /in/DQShV on line 13
Fatal error: Class jhdatetime: Cannot inherit from undefined class datetime in /in/DQShV on line 4