php get week first day name from week number code example
Example 1: php get day of week
date('w');
if(date('w') == 1){
echo "its monday baby";
}
Example 2: week starting date and end date in php
<?php$week=29;$year=2017;function getStartAndEndDate($week, $year) { $dateTime = new DateTime(); $dateTime->setISODate($year, $week); $result['start_date'] = $dateTime->format('d-M-Y'); $dateTime->modify('+6 days'); $result['end_date'] = $dateTime->format('d-M-Y'); return $result;}$dates=getStartAndEndDate($week,$year);print_r($dates);?>