note 47838 added to function.date-sunset

From: Date: Thu, 02 Dec 2004 09:39:32 +0000
Subject: note 47838 added to function.date-sunset
Groups: php.notes 
Request: Send a blank email to php-notes+get-81264@lists.php.net to get a copy of this message
A way to use this: <?php // De Bilt, The Netherlands, weather station #06260 $lat = 52.10; // North $long = 5.18; // East $offset = 1; // difference between GMT and local time in hours $zenith=90+50/60; echo "<br><p>Sunrise: ".date_sunrise(time(), SUNFUNCS_RET_STRING, $lat, $long, $zenith, $offset); echo "<br>Sunset: ".date_sunset(time(), SUNFUNCS_RET_STRING, $lat, $long, $zenith, $offset); $zenith=96; echo "<br><p>\"Civilian Twilight\" start: ".date_sunrise(time(), SUNFUNCS_RET_STRING, $lat, $long, $zenith, $offset); echo "<br>\"Civilian Twilight\" end: ".date_sunset(time(), SUNFUNCS_RET_STRING, $lat, $long, $zenith, $offset); $zenith=102; echo "<br><p>\"Nautical Twilight\" start: ".date_sunrise(time(), SUNFUNCS_RET_STRING, $lat, $long, $zenith, $offset); echo "<br>\"Nautical Twilight\" end: ".date_sunset(time(), SUNFUNCS_RET_STRING, $lat, $long, $zenith, $offset); $zenith=108; echo "<br><p>\"Astronomical Twilight\" start: ".date_sunrise(time(), SUNFUNCS_RET_STRING, $lat, $long, $zenith, $offset); echo "<br>\"Astronomical Twilight\" end: ".date_sunset(time(), SUNFUNCS_RET_STRING, $lat, $long, $zenith, $offset); ?> Thanks to George King. More sources about this topic: http://www.qarlos.free.fr/navegacion/Sextante/formulas.htm http://williams.best.vwh.net/sunrise_sunset_algorithm.htm http://www.kevinboone.com/suntimes.html http://star-www.st-and.ac.uk/~fv/webnotes/chapt12.htm ---- Manual Page -- http://www.php.net/manual/en/function.date-sunset.php Edit -- http://master.php.net/manage/user-notes.php?action=edit+47838 Delete -- http://master.php.net/manage/user-notes.php?action=delete+47838&report=yes Reason: bad code -- http://master.php.net/manage/user-notes.php?action=delete+47838&report=yes&reason=bad+code Reason: spam -- http://master.php.net/manage/user-notes.php?action=delete+47838&report=yes&reason=spam Reason: useless example -- http://master.php.net/manage/user-notes.php?action=delete+47838&report=yes&reason=useless+example Reason: contains commercial links -- http://master.php.net/manage/user-notes.php?action=delete+47838&report=yes&reason=contains+commercial+links Reason: useless note -- http://master.php.net/manage/user-notes.php?action=delete+47838&report=yes&reason=useless+note Reject -- http://master.php.net/manage/user-notes.php?action=reject+47838&report=yes Search -- http://master.php.net/manage/user-notes.php

« previous php.notes (#81264) next »