Home : Products : DBMan SQL : Discussion :

Products: DBMan SQL: Discussion: Re: [donm] Query help?: Edit Log

Here is the list of edits for this post
Re: [donm] Query help?
ops I mean the Template Globals in Admin panel >> Templates where you can set a global tag (i.e. something => a value) or a simple function (return a value) then you can simply get a new tag <%something%> to display that value in your templates.
Quote:
What I have in the "date_exp" field is the date of expiration in the form of "2001-11-26".
So you can replace the code above with :
my $date_exp_num = GT::Date::date_diff($tag->{date_exp},$today) ; # which returns number of days difference between date_exp and today.
and customize things like :
if ($date_exp_num < 0) {
....expired....
}
elsif ($date_exp_num < 30) {
...will expire within the next $date_exp_num days
}

Cheers,
jean@gossamer-threads.com


Last edited by:

jean: Nov 26, 2001, 5:56 PM

Edit Log: