tags:

views:

185

answers:

2

How would I covert a date formatted like this Thu, 08 Jul 2010 15:51:01 into a date like this Thursday July 8th, 2010 3:51 pm. Also, how would I filter the first sting to not include time, so that it could look like this in the end Thursday July 8th, 2010

+1  A: 

http://pl2.php.net/manual/en/function.date.php

echo date("l F jS, Y", strtotime("Thu, 08 Jul 2010 15:51:01"));
Svisstack
Thanks, works great. I looked at the manual for awhile before and it wasn't working. I was missing the strtotime part.
brandon14_99
A: 

Hi there, you can take a look at all of the possible date formatting options here http://www.php.net/manual/en/function.date.php

Basically, with the date() function you construct a date in any format you want, for example

echo date('l M d, Y');

would output Thursday Apr 29, 2010

falomir