...

View Full Version : Date/Time Format



xsnoboard
01-12-2006, 03:22 AM
i want my date/time format to be a normal format... ex. 1-11-2006 9:20pm..

it comes out for me like 2006-1-11 21:00:30


code i have is... how could i have it so it displays it normally...


<?php echo $filelist_array["date"]; ?>

devinemke
01-12-2006, 03:43 AM
$date = '2006-1-11 21:00:30';
echo date('n-d-Y g:ia', strtotime($date));

xsnoboard
01-12-2006, 04:32 AM
i dont want to have date = to a specified ammount... it changes everytime i add new material to my site

xsnoboard
01-12-2006, 04:37 AM
from this code this is the output i get: 12-31-1969 6:59pm


<?php $date = '$filelist_array["date"]';
echo date('n-d-Y g:ia', strtotime($date)); ?>

devinemke
01-12-2006, 04:39 AM
echo date('n-d-Y g:ia', strtotime($filelist_array['date']));

xsnoboard
01-12-2006, 05:44 AM
I fricken love you man...


Thanks alot it works



EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum