How do I convert this date 072304 to July 23rd, 2004 ? The original date I have is in the date("mdy") format and I need to ouput it in a different format. Can someone please help me with this?
Thanks
<?php $date = "072304"; $ts = strtotime(substr($date,0,2) . '/' . substr($date,2,2) . '/' . substr($date,4)); echo date('F d, Y',$ts); ?>
Prints out: July 23, 2004
Thanks very much 🙂