How to get all months in php?

Get all months in php
for ($m=1; $m<=12; $m++)
{
$month = date(‘F’, mktime(0,0,0,$m, 1, date(‘Y’)));
echo $month;
}

Leave a Reply

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