Possible Duplicate:
php strtotime “last monday” if today is monday?
I want to get some information from the database from this current week.
So what do i need? The first monday (date) and the next sunday (date).
This code works fine, but:
$fm = date('Y-m-d', strtotime('last monday', time()));
$lz = date('Y-m-d', strtotime('next sunday', time()));
But when it IS monday this doesnt work? It gives me a total different date.
What can i do to prevent this?