If you want to convert number to month name than use below code:

$dateObj   = DateTime::createFromFormat('!m', $post_row['month']);
echo $monthName = $dateObj->format('F'); // March
Please login or Register to submit your answer

Log In

Not the answer you are looking for? Browse other questions tagged or ask your own question.