Gossamer Forum
Home : Products : Gossamer Links : Development, Plugins and Globals :

Categories from a link in the detailed page

Quote Reply
Categories from a link in the detailed page
Hi,

I´m using the following global to include the categories from a link in the detailed page

-----------------------------
sub {
my $tags = shift;
my $seen;
my $id = $tags->{'ID'};
my $db = $DB->table ('Category','CatLinks');
my $sth = $db->select ( { LinkID => $id }, ['Name','Full_Name'] );
my $cat;
while (my ($name,$full_name) = $sth->fetchrow_array) {
if ($seen->{$name}) { next; }
$full_name =~ s/ /_/g;
$cat .= qq~<a href="$CFG->{build_root_url}/$full_name/index.html">$name</a><br>~;
$seen->{$name} = 1;
}
return $cat;
}
-------------------------------

I would need some categories not to appear. For example the categories with these Id:

ID=234
ID=3
ID=112

Could someone indicate what I should do on the global?

Thanks in advance.

JoseML
Subject Author Views Date
Thread Categories from a link in the detailed page JoseML 8444 Apr 29, 2008, 4:02 PM
Thread Re: [JoseML] Categories from a link in the detailed page
Andy 8289 Apr 29, 2008, 11:35 PM
Thread Re: [Andy] Categories from a link in the detailed page
JoseML 8245 May 1, 2008, 3:17 AM
Thread Re: [JoseML] Categories from a link in the detailed page
JoseML 8204 Aug 20, 2008, 6:08 PM
Thread Re: [JoseML] Categories from a link in the detailed page
Andy 8191 Aug 20, 2008, 11:56 PM
Thread Re: [Andy] Categories from a link in the detailed page
JoseML 8165 Aug 21, 2008, 5:08 PM
Thread Re: [JoseML] Categories from a link in the detailed page
Andy 8176 Aug 21, 2008, 11:24 PM
Thread Re: [Andy] Categories from a link in the detailed page
JoseML 8136 Aug 22, 2008, 3:07 AM
Thread Re: [JoseML] Categories from a link in the detailed page
Andy 8137 Aug 22, 2008, 3:11 AM
Thread Re: [Andy] Categories from a link in the detailed page
JoseML 8189 Aug 22, 2008, 5:36 AM
Thread Re: [JoseML] Categories from a link in the detailed page
Andy 8166 Aug 22, 2008, 5:46 AM
Post Re: [Andy] Categories from a link in the detailed page
JoseML 8120 Aug 23, 2008, 2:42 AM