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 5446 Apr 29, 2008, 4:02 PM
Thread Re: [JoseML] Categories from a link in the detailed page
Andy 5359 Apr 29, 2008, 11:35 PM
Thread Re: [Andy] Categories from a link in the detailed page
JoseML 5305 May 1, 2008, 3:17 AM
Thread Re: [JoseML] Categories from a link in the detailed page
JoseML 5262 Aug 20, 2008, 6:08 PM
Thread Re: [JoseML] Categories from a link in the detailed page
Andy 5253 Aug 20, 2008, 11:56 PM
Thread Re: [Andy] Categories from a link in the detailed page
JoseML 5232 Aug 21, 2008, 5:08 PM
Thread Re: [JoseML] Categories from a link in the detailed page
Andy 5233 Aug 21, 2008, 11:24 PM
Thread Re: [Andy] Categories from a link in the detailed page
JoseML 5203 Aug 22, 2008, 3:07 AM
Thread Re: [JoseML] Categories from a link in the detailed page
Andy 5211 Aug 22, 2008, 3:11 AM
Thread Re: [Andy] Categories from a link in the detailed page
JoseML 5249 Aug 22, 2008, 5:36 AM
Thread Re: [JoseML] Categories from a link in the detailed page
Andy 5239 Aug 22, 2008, 5:46 AM
Post Re: [Andy] Categories from a link in the detailed page
JoseML 5204 Aug 23, 2008, 2:42 AM