first let me show you my code:
$lastWeek = date('m-d-Y', strtotime('-1 week'));
That’s how to get the timestamp from last week.
Is there a chance I gan get the timestamp from last saturday?
I hope you know what I mean.
Thanks a lot.
Here is Solutions:
We have many solutions to this problem, But we recommend you to use the first solution because it is tested & true solution that will 100% work for you.
What’s wrong with
$last_sat = strtotime("last Saturday");
The time should be set to ’00:00:00′;
echo date('d-M-Y H:i:s',$last_sat);
Note: Use and implement solution 1 because this method fully tested our system.
Thank you 🙂