Could anyone point me in the right direction or create a function (which would be brilliant), that takes a date, input by the user and returns the date of the Monday prior to that date.
Any assistance would be most appreciated.
echo date('Y-m-d',strtotime('last monday',time()));
where time() can be any unixtimestamp
Thanks a million sidney, isn't it easy when you know how!!
I finished up with:
$search_date = date('Y-m-d',strtotime('last monday',mktime(0, 0, 0, $_GET['month'], $_GET['day'],$_GET['year'])));
which works a treat.