3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php echo cal_days_in_month(999, 1,-1), PHP_EOL, cal_days_in_month(CAL_JEWISH, 1,-1), PHP_EOL, cal_days_in_month(CAL_FRENCH, 1,-1), PHP_EOL, cal_days_in_month(CAL_JULIAN, 1,-1), PHP_EOL, cal_days_in_month(CAL_GREGORIAN, 1,-1), PHP_EOL;
based on lCgsj
Output for 4.4.0 - 4.4.9, 5.0.5 - 7.1.0
Warning: cal_days_in_month(): invalid calendar ID 999. in /in/UYvqo on line 3 Warning: cal_days_in_month(): invalid date. in /in/UYvqo on line 4 Warning: cal_days_in_month(): invalid date. in /in/UYvqo on line 5 31 31
Output for 5.0.2 - 5.0.4
Warning: cal_days_in_month(): invalid calendar ID 999. in /in/UYvqo on line 3 0 0 31 31
Output for 5.0.0 - 5.0.1
Warning: cal_days_in_month(): invalid calendar ID 999. in /in/UYvqo on line 3 Notice: Use of undefined constant PHP_EOL - assumed 'PHP_EOL' in /in/UYvqo on line 3 PHP_EOL0 Notice: Use of undefined constant PHP_EOL - assumed 'PHP_EOL' in /in/UYvqo on line 4 PHP_EOL0 Notice: Use of undefined constant PHP_EOL - assumed 'PHP_EOL' in /in/UYvqo on line 5 PHP_EOL31 Notice: Use of undefined constant PHP_EOL - assumed 'PHP_EOL' in /in/UYvqo on line 6 PHP_EOL31 Notice: Use of undefined constant PHP_EOL - assumed 'PHP_EOL' in /in/UYvqo on line 7 PHP_EOL
Output for 4.3.10 - 4.3.11
Warning: cal_days_in_month(): invalid calendar ID 999 in /in/UYvqo on line 3 0 0 31 31
Output for 4.3.0 - 4.3.9
Warning: cal_days_in_month(): invalid calendar ID 999 in /in/UYvqo on line 3 Notice: Use of undefined constant PHP_EOL - assumed 'PHP_EOL' in /in/UYvqo on line 3 PHP_EOL0 Notice: Use of undefined constant PHP_EOL - assumed 'PHP_EOL' in /in/UYvqo on line 4 PHP_EOL0 Notice: Use of undefined constant PHP_EOL - assumed 'PHP_EOL' in /in/UYvqo on line 5 PHP_EOL31 Notice: Use of undefined constant PHP_EOL - assumed 'PHP_EOL' in /in/UYvqo on line 6 PHP_EOL31 Notice: Use of undefined constant PHP_EOL - assumed 'PHP_EOL' in /in/UYvqo on line 7 PHP_EOL