Gossamer Forum
Home : Products : Gossamer Links : Version 1.x :

Date Display

Quote Reply
Date Display
I managed to locally diplay the date in the format Apr 7 by inserting this code into the HTML_Templates.pm

sub convert_date {
# ---------------------------------------
my $in = shift;
my %months = qw!1 Jan 2 Feb 3 Mar 4 Apr 5 May 6 Jun 7 Jul 8 Aug 9 Sep 10 Oct 11 Nov 12 Dec!;
my ($year, $mon, $day) = split /-/, $in;
return "$months{int $mon} $day";
}

However, recently I changed the Add_Date field Type to DATETIME. Now the page dispalys Apr 7 10:04:38

If anyone has any ideas on how I can cut the 10:04:38 from dispaying, much appreciated.
Thanks.
Subject Author Views Date
Thread Date Display Brian Dentry 1565 Apr 6, 2000, 3:38 PM
Post Re: Date Display
pugdog 1467 Apr 7, 2000, 7:40 PM
Post Re: Date Display
Brian Dentry 1479 Apr 8, 2000, 10:12 PM
Post Re: Date Display
Brian Dentry 1482 Apr 13, 2000, 1:00 AM
Post Re: Date Display
pugdog 1472 Apr 13, 2000, 3:14 AM
Post Re: Date Display
Brian Dentry 1479 Apr 13, 2000, 7:52 AM
Post Re: Date Display
pugdog 1490 Apr 13, 2000, 11:06 AM