Date Format Question

liunx

Guest
In my (MySQL) database, I have dates in the standard yyyy-mm-dd format and was wondering how to convert it on screen to read the date printed out (ie: 2007-01-31 would read January 31st, 2007 or just January 31st).<br /><br />I'd appreciate any help. I've tried googling this but nothing came up that was helpful...<!--content-->
You can do it with PHP. See <a href="http://us2.php.net/date" target="_blank">this page</a>.<br /><br /><!--c1--><div class='codetop'>CODE</div><div class='codemain'><!--ec1--><?php<br />echo date("F jS, Y");<br />?><!--c2--></div><!--ec2--><!--content-->
<!--quoteo(post=199646:date=Jan 31 2007, 11:26 AM:name=TCH-Bruce)--><div class='quotetop'>QUOTE(TCH-Bruce @ Jan 31 2007, 11:26 AM) <a href="http://www.totalchoicehosting.com/forums/index.php?act=findpost&pid=199646"><img src='http://www.totalchoicehosting.com/forums/style_images/1/post_snapback.gif' alt='*' border='0' /></a></div><div class='quotemain'><!--quotec-->You can do it with PHP. See <a href="http://us2.php.net/date" target="_blank">this page</a>.<br /><br /><!--c1--><div class='codetop'>CODE</div><div class='codemain'><!--ec1--><?php<br />echo date("F jS, Y");<br />?><!--c2--></div><!--ec2--><!--QuoteEnd--></div><!--QuoteEEnd--><br /><br />Excellent, thanks Bruce! <img src="http://www.totalchoicehosting.com/forums/style_emoticons/default/thumbup1.gif" style="vertical-align:middle" emoid=":thumbup1:" border="0" alt="thumbup1.gif" /><!--content-->
 
Back
Top