Displaying dates as (i.e) 23 Oct 2002

Questions about the MySQL, PostgreSQL, and most other databases, as well as using it with PHP can be asked here.

Moderator: General Moderators

Post Reply
Bob.H
Forum Newbie
Posts: 2
Joined: Thu Oct 17, 2002 3:26 am

Displaying dates as (i.e) 23 Oct 2002

Post by Bob.H »

Hi,

I have a mysql driven webpage showing future events and meetings. However, at the moment the start dates and end dates are displayed as 10-10-2002 and 12-10-2002. See below:-

Code: Select all

<?php
// Print the dates for the event
	  $rowї"startd"] = substr($rowї"start_date"], 8, 2) . "-" .
                  		substr($rowї"start_date"], 5, 2) . "-" .   
                  		substr($rowї"start_date"], 0, 4) . "  ";
	 $rowї"endd"] = substr($rowї"end_date"], 8, 2) . "-" .
                  		substr($rowї"end_date"], 5, 2) . "-" .   
                  		substr($rowї"end_date"], 0, 4); 
?>
What I would like to see is 10th Oct 2003 and 12th Oct 2003. Can anybody help me with this please.

Thanks in advance.

Bob.H. :cry:
User avatar
twigletmac
Her Royal Site Adminness
Posts: 5371
Joined: Tue Apr 23, 2002 2:21 am
Location: Essex, UK

Post by twigletmac »

Post Reply