Gossamer Forum
Home : Products : Links 2.0 : Customization :

Re: [Hamsterpants] Yahoo

Quote Reply
Re: [Hamsterpants] Yahoo In reply to
Here is the simple way to do it:



# Then we print out the name linked, new if it's new, and popular if its popular.
$output .= qq|<dl><dt><strong><a class="link" href="$url">$category_name</a></strong> <small class="numlinks">($numlinks)</small> |;
my $days_old = &days_old($mod) / $db_new_cutoff;
if ($days_old <= 0.3) { $output .= qq| $new1|; }
elsif ($days_old <= 0.6) { $output .= qq| $new2|; }
elsif ($days_old <= 1) { $output .= qq| $new3|; }
if ($mod eq "Yes") { $output .= qq~ $updated~; }
$output .= qq|</dt>|;

if ($#{$subcategories{$subcat}} >= 0) {
$v = 0;
$output .= qq~<BR><SPAN CLASS="xsmall">~;
foreach $subcatsub (sort @{$subcategories{$subcat}}) {
$suburl = "$build_root_url/" . &urlencode($subcatsub) . "/";
if ($subcatsub =~ m,.*/([^/]+)$,) {$subcategory_name = &build_clean($1);}
else {$subcategory_name = &build_clean($subcatsub);}
$output .= qq~<A HREF="$suburl">$subcategory_name</A>~ if ($v <= 5);
$output .= qq~<font color="#000000">...</font>~ if ($v eq "5");
$output .= qq~<font color="#000000">, </font>~ if ($v ne $#{$subcategories{$subcat}} && $v <= 5);
$v++;
}
$output .= qq~</SPAN>~;
}


$output .= qq|<dd><span class="descript">$description </span></dd>| if (!($description =~ /^[\s\n]*$/));
$output .= qq|</dl>|;
}

# Don't forget to end the unordered list..


It's from this post: http://www.gossamer-threads.com/...late-version;#127003 Just watch this part: <SPAN CLASS="xsmall"> You will ned to change it to match what you have (or use HTML).


Leonard
aka PerlFlunkie
Subject Author Views Date
Thread Yahoo Hamsterpants 2869 Feb 27, 2003, 1:37 AM
Thread Re: [Hamsterpants] Yahoo
PerlFlunkie 2833 Feb 27, 2003, 2:19 AM
Thread Re: [PerlFlunkie] Yahoo
Hamsterpants 2831 Feb 27, 2003, 2:48 AM
Thread Re: [Hamsterpants] Yahoo
PerlFlunkie 2816 Feb 27, 2003, 12:17 PM
Post Re: [PerlFlunkie] Yahoo
Hamsterpants 2790 Feb 27, 2003, 10:58 PM