Gossamer Forum
Quote Reply
christmas favor:)
I'm trying to use the days old plugin from a template used for a global name last_links, but however it does not work.

I tried to copy the sub from the days_old plugin and use it as a global, but however the global return nothing.. can someone help me?



sub link {

# -------------------------------------------------------------------

# This subroutine will get called whenever the hook 'site_html_link'

# is run. You should return STOP if you don't want

# the regular code to run, or CONTINUE if you want

# the regular code to run.

#

my $link = shift;

# added line to preserve Add_Date from Links table row

$link->{Add_Date1} = $link->{Add_Date} ;

# Links Days_Old calculate

# Figure out how many days old it is if it's a new link.

if ($link->{'isNew'} eq 'Yes') {

$link->{'Days_Old'} = GT::Date::date_diff ( GT::Date::date_get(), $link->{'Add_Date1'});

}

else {

$link->{'Days_Old'} = '';

}

return $link;

}

Subject Author Views Date
Thread christmas favor:) xpert 7295 Dec 25, 2002, 6:41 PM
Post Re: [xpert] christmas favor:)
Andy 7178 Dec 26, 2002, 1:58 AM
Thread Re: [xpert] christmas favor:)
Paul 7224 Dec 26, 2002, 2:02 AM
Thread Re: [Paul] christmas favor:)
xpert 7126 Dec 26, 2002, 9:10 AM
Thread Re: [xpert] christmas favor:)
xpert 7120 Dec 26, 2002, 1:20 PM
Thread Re: [xpert] christmas favor:)
Paul 7119 Dec 26, 2002, 2:49 PM
Thread Re: [Paul] christmas favor:)
xpert 7104 Dec 26, 2002, 4:09 PM
Thread Re: [xpert] christmas favor:)
xpert 7151 Dec 27, 2002, 3:35 AM
Thread Re: [xpert] christmas favor:)
xpert 7114 Dec 28, 2002, 1:13 PM
Post Re: [xpert] christmas favor:)
webmaster33 7079 Dec 28, 2002, 2:49 PM
Thread Re: [xpert] christmas favor:)
pugdog 7092 Dec 29, 2002, 8:10 AM
Thread Re: [pugdog] christmas favor:)
xpert 7090 Dec 29, 2002, 3:19 PM
Thread Re: [xpert] christmas favor:)
pugdog 7063 Dec 29, 2002, 9:41 PM
Thread Re: [pugdog] christmas favor:)
xpert 7049 Dec 29, 2002, 9:45 PM
Thread Re: [xpert] christmas favor:)
pugdog 7062 Dec 30, 2002, 12:32 PM
Thread Re: [pugdog] christmas favor:)
xpert 7027 Jan 9, 2003, 7:14 PM
Post Re: [xpert] christmas favor:)
xpert 6963 Jan 10, 2003, 4:57 PM