How to work out what was the date of the last Sunday using PHP

Description

Here is a code snippet to work out the date of the last Sunday:

echo date('Y-m-d',strtotime('last sunday'));

Reference

https://stackoverflow.com/questions/15196587/get-last-sunday-date-in-php/15196691

Share this article

Leave a Reply

Your email address will not be published. Required fields are marked *

Scroll to Top