How I can get sunday of last week on the month with Carbon?
$startDate = Carbon::now()->endOfMonth();
$lastSunday = $startDate()->endOfWeek();
Not working. Thanks.
You can use Carbon like this:
Carbon::parse('last sunday of this month')
This will return Carbon instance with the last Sunday of current month.