Gossamer Forum
Home : Products : Links 2.0 : Customization :

Categories in 3 rows, how?

Quote Reply
Categories in 3 rows, how?
The title says it all, how do I make the categories appear in 3 rows? Probably has to do something with site_html_templates.pl but I can't figure out where

Please reply :-) Cheers!
Quote Reply
Re: [Kaz] Categories in 3 rows, how? In reply to
Did you search the forums? Use the 'Search Posts' link found on every page, this subject was covered recently...


Leonard
aka PerlFlunkie
Quote Reply
Re: [PerlFlunkie] Categories in 3 rows, how? In reply to
PerlFlunkie, I understand that's it your job to motivate people to use the search option instead asking the same questions, but could you cut me some slack on this one :) I DID do a search and came up with nothing btw ;)
Quote Reply
Re: [Kaz] Categories in 3 rows, how? In reply to
What exactly are you wanting to do? Do you want to limit the number of ROWS (horizontal), or change the number of COLUMNS (verticle)? The search works great, but sometimes you do need to have just the right keywords... Does this link do what you want?



...cut cut....Smile


Leonard
aka PerlFlunkie
Quote Reply
Re: [PerlFlunkie] Categories in 3 rows, how? In reply to
I really don't understand what the guy from that post wants heh.

All I'm looking for is to change the listing of categories from 2 columns to 3 that's all :)



Thanx bud
Quote Reply
Re: [Kaz] Categories in 3 rows, how? In reply to
Try this, from my ancient hard-copy file...

In either site_html.pl (non-templates) or site_html_templates.pl (templates), go to sub site_html_print_cat (bottom of file).

Change:

my ($half) = int (($#subcat=2) / 2);

To:

$columns ='3'; #number of columns
my ($half) = int (($#subcat+2) / $columns);


Change:

if ($i == $half) {
$output .= qq~</td><td class="catlist" valign="top">\n~;
}

To:

if ($i == $half) {
$output .= qq~</td><td class="catlist" valign="top">\n~;
$i = 0;
}



Leonard
aka PerlFlunkie
Quote Reply
Re: [PerlFlunkie] Categories in 3 rows, how? In reply to
exactly what I needed :D thanx for taking the time to actually get this from a hard-copy :)
Quote Reply
Re: [PerlFlunkie] Categories in 3 rows, how? In reply to
works like a charm:)