Gossamer Forum
Home : Products : Links 2.0 : Customization :

Category Columns

Quote Reply
Category Columns
Hi Everyone,
I was just curious to see if you can have the category listings look different on the index page and category pages? I want the two normal columns on the index page, but I want the category listings on the category pages in three columns, is this possible? If so, how? - If this has been asked in the past, please point me to the page - thanx

------------------
Thank you,
Bryce E. Jones
Surfzpuppy, Inc. -CEO
http://www.surfzpuppy.com
Quote Reply
Re: Category Columns In reply to
To do that, you would need two different routines. Currently, the sub routine that creates the category lists for all category and home page is sub site_html_print_cat. To do a seperate one for the home page, just copy it to something like sub site_html_home_print_cat and modify either of them to display the way you want them to. Just be sure to change the call to &site_html_print_cat to &site_html_home_print_cat in the sub build_home_page in nph-build.cgi.

As to how to get 3 columns, that is a good exercise in html design. I have done it previously, but never liked how it looked. I have since gone to using tables within tables within tables to do what I want. However, you can find my old code example at http://www.orphanage.com/goodstuff/hometree.html and the source code at http://www.orphanage.com/goodstuff/hometree.txt
Quote Reply
Re: Category Columns In reply to
How do I have the categories displayed in one column?

Keith Kaiser
Quote Reply
Re: Category Columns In reply to
Keith,

You need to edit sub site_html_print_cat in either site_html.pl or site_html_templates.pl (if using templates in v2.0). Look for the $half variable and how it is used. I think you will see what you need to delete to get one column.

I hope this helps.
Quote Reply
Re: Category Columns In reply to
Hey thanks for all of your help - I got it to work good. Can yout ell me what I need t ochange to make into 4 columns, I think it would look much cleaner with my site layout - If you want, you can see it at surfzpuppy.com



------------------
Thank you,
Bryce E. Jones
Surfzpuppy, Inc. -CEO
http://www.surfzpuppy.com


[This message has been edited by puppyz (edited March 02, 1999).]
Quote Reply
Re: Category Columns In reply to
puppyz,

Using the same variables in the same script, you can make it display 4 columns. Just change the "/2" part to "/4" and play with the routine.

By the way, your page displayed fine in Netscape 4, but in Netscape 3, your right column of categories is off the page (just the left most portion is showing. Must be that darned css stuff again. Smile

[This message has been edited by Bobsie (edited March 03, 1999).]