Forums
This topic is locked
Formatting Date in PHP
Posted 02 Feb 2007 18:56:34
1
has voted
02 Feb 2007 18:56:34 John Alexander Hopper posted:
HiJust wondering if anyone can help me with the formatting of the date in PHP/MySQL?
One of the fields in my Database is 'updated', which updated with an 'on_update_current_timestamp'.
When I display this field on my PHP pages, it comes out like 2007-01-29 22:37:41.
How would I format this so it displayed as 'January 29th, 2007 at 22:37', or even just the date?
Thanks
John Alexander Hopper
Replies
Replied 02 Feb 2007 19:29:30
02 Feb 2007 19:29:30 Roddy Dairion replied:
date('F dS, Y at H:i', strtostring($fieldname));
Hope this works
Hope this works