3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php echo strtotime("2006-12-12"); echo "<pre>"; $sun_info = date_sun_info(strtotime("2006-12-12"), 31.7667, 35.2333); print_r($sun_info); foreach ($sun_info as $key => $val) { echo "$key: " . date("H:i:s", $val) . "\n"; } ?>
Output for 5.2.2 - 7.1.0
1165878000<pre>Array ( [sunrise] => 1165897780 [sunset] => 1165934167 [transit] => 1165915974 [civil_twilight_begin] => 1165896175 [civil_twilight_end] => 1165935773 [nautical_twilight_begin] => 1165894351 [nautical_twilight_end] => 1165937596 [astronomical_twilight_begin] => 1165892568 [astronomical_twilight_end] => 1165939379 ) sunrise: 05:29:40 sunset: 15:36:07 transit: 10:32:54 civil_twilight_begin: 05:02:55 civil_twilight_end: 16:02:53 nautical_twilight_begin: 04:32:31 nautical_twilight_end: 16:33:16 astronomical_twilight_begin: 04:02:48 astronomical_twilight_end: 17:02:59
Output for 5.1.3 - 5.2.1
1165878000<pre>Array ( [sunrise] => 1165899131 [sunset] => 1165934481 [transit] => 1165916806 [civil_twilight_begin] => 1165897448 [civil_twilight_end] => 1165936164 [nautical_twilight_begin] => 1165895545 [nautical_twilight_end] => 1165938066 [astronomical_twilight_begin] => 1165893692 [astronomical_twilight_end] => 1165939920 ) sunrise: 05:52:11 sunset: 15:41:21 transit: 10:46:46 civil_twilight_begin: 05:24:08 civil_twilight_end: 16:09:24 nautical_twilight_begin: 04:52:25 nautical_twilight_end: 16:41:06 astronomical_twilight_begin: 04:21:32 astronomical_twilight_end: 17:12:00
Output for 5.0.0 - 5.1.2
1165878000<pre> Fatal error: Call to undefined function date_sun_info() in /in/tD8m2 on line 5
Process exited with code 255.
Output for 4.4.5 - 4.4.9
1165878000<pre> Fatal error: Call to undefined function: date_sun_info() in /in/tD8m2 on line 5
Process exited with code 255.
Output for 4.3.2 - 4.4.4
1165878000<pre> Fatal error: Call to undefined function: date_sun_info() in /in/tD8m2 on line 5
Process exited with code 255.
Output for 4.3.0 - 4.3.1
1165878000<pre> Fatal error: Call to undefined function: date_sun_info() in /in/tD8m2 on line 5