I want to get last month\'s date. I wrote this out:
$prevmonth = date(\'M Y\');
Which gives me the current month/year. I can\'t tell if I
$lastMonth = date('M Y', strtotime("-1 month")); var_dump($lastMonth); $lastMonth = date('M Y', mktime(0, 0, 0, date('m') - 1, 1, date('Y'))); var_dump($lastMonth);