View Full Version : Date/Time Format

01-12-2006, 02: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"]; ?>

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

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

01-12-2006, 03: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)); ?>

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

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

Thanks alot it works

EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum