| « PHP Date Time: Finding The Number of Days in a Month | PHP Date Time: Finding The Number of Weeks in Year Number fo... » |
PHP Date Time: Finding the Day in Year Number for a Date
PHP Date Time Tips - Part 8:Do you want to find the day-in-year for a particular date? You can use date() function with the "z" modifier. Like this:
<?php
// get day of year for 08 aug 2008
// result 221
echo date("z", mktime(0,0,0,8,8,2008))+1;
?>

