Displaying a timestamp in different formats
Posted: Thu Jul 16, 2009 1:19 pm
Hi
As part of a news system I am constructing, each post will have a timestamp. It is entered into my database in the following format: 2009-07-02 14:13:41
To display this on a page I am using this code:
Is it possible to display this timestamp (2009-07-02 14:13:41) in different formats, such as in the format of d/m/y ?
Thanks for any help.
As part of a news system I am constructing, each post will have a timestamp. It is entered into my database in the following format: 2009-07-02 14:13:41
To display this on a page I am using this code:
Code: Select all
<?php echo $row->timestamp; ?>Thanks for any help.