Gossamer Forum
Home : Products : DBMan SQL : Discussion :

Re: [jayridgway] html code for date display

Quote Reply
Re: [jayridgway] html code for date display In reply to
You should create a global template called 'get_date':

sub {
my $field_name = shift;
my $tags = GT::Template->tags;
my $home = $tags->{home};
require GT::Date;
GT::Date::date_set_format('%mm%-%dd%-%yyyy%');
$home->{db}->cols->{$field_name}->{default} = GT::Date::date_get();
}

Change add_form.html like:

....
<%get_date('your_date_field_name')%>
<%generate_add_form%>
...

Hope that helps.

TheStone

B.
Subject Author Views Date
Thread html code for date display jayridgway 5395 Jun 18, 2002, 11:43 AM
Thread Re: [jayridgway] html code for date display
604 5252 Jun 19, 2002, 10:03 AM
Thread Re: [TheStone] html code for date display
jayridgway 5235 Jun 19, 2002, 10:36 AM
Thread Re: [jayridgway] html code for date display
Reena0330 5150 Aug 6, 2002, 2:14 PM
Post Re: [Reena0330] html code for date display
Reena0330 5140 Aug 6, 2002, 4:16 PM