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 4547 Jun 18, 2002, 11:43 AM
Thread Re: [jayridgway] html code for date display
604 4427 Jun 19, 2002, 10:03 AM
Thread Re: [TheStone] html code for date display
jayridgway 4409 Jun 19, 2002, 10:36 AM
Thread Re: [jayridgway] html code for date display
Reena0330 4326 Aug 6, 2002, 2:14 PM
Post Re: [Reena0330] html code for date display
Reena0330 4316 Aug 6, 2002, 4:16 PM