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

Global to List Contributors

Quote Reply
Global to List Contributors
Hi:



I have been playing with the idea of a global to output a bulleted list of those users who have contributed something to my list. I have written a rough out line, but come up with a couple of problems I cannot solve. (Note the "#" comments) Here is the current code:



Quote:




sub {

my ($person, $cont);

my $link_db = $DB->table('Links');

my $contrib = $link_db->select ( { LinkOwner => admin }, ['LinkOwner'] ); #Want LinkOwner NE admin

# need line to count each LinkOwner only once!

while ($person = $contrib->fetchrow_hashref) {

push $person;

$cont.= qq~<DD><IMG SRC="/pages/images/button.gif"> <A HREF="http://www.bcdb.com/bcdb/edit_login.cgi?g=Profile&user_name=${$person}{'LinkOwner'}">${$person}{'LinkOwner'}</A>\n~;

}

return $cont;

}


The first problem is I want it to pull LinkOwners that are NOT admin.... is this possible?



Second, I only need to pull each contributor's name once... and some people have added multiple items. I need to know how to ignore multiples of the same name..



Any help would be appreciated!



Thanks!
dave

Big Cartoon DataBase
Big Comic Book DataBase
Subject Author Views Date
Thread Global to List Contributors carfac 2812 Aug 13, 2002, 12:51 PM
Thread Re: [carfac] Global to List Contributors
Aki 2729 Aug 13, 2002, 3:48 PM
Thread Re: [Aki] Global to List Contributors
carfac 2714 Aug 13, 2002, 5:01 PM
Post Re: [carfac] Global to List Contributors
carfac 2701 Aug 13, 2002, 5:34 PM