php convert month number to name

83

php convert month number to name -

$monthNum  = 3;
$dateObj   = DateTime::createFromFormat('!m', $monthNum);
$monthName = $dateObj->format('F'); // March

Comments

Submit
0 Comments