Created
June 14, 2015 12:14
-
-
Save giorgiosironi/4616671fafb3098a4369 to your computer and use it in GitHub Desktop.
bugged version of fromZeroBasedDayOfYear()
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function fromZeroBasedDayOfYear($year, $dayOfYear) | |
{ | |
return DateTime::createFromFormat( | |
'z Y H i s', | |
$dayOfYear . ' '. $year . ' 00 00 00', | |
new DateTimeZone("UTC") | |
); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment