
Here is the code to do it. try it and comment if you got error.
$mydate= '2014-11-11'; $time = strtotime($mydate); $start = strtotime('last sunday', $time); $end = strtotime('next saturday', $time); $format = 'l, F j, Y '; $start_day = date($format, $start); $end_day = date($format, $end); echo "Mydate: $s\nResult: $start_day - $end_day";
Leave a Reply