Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

Category table size issue


EricB

Recommended Posts

I'm working on a site that sells performance parts for cars. The shop has quote a few categories, most of which have many sub-categories.

 

The problem is that when you start getting into some of the deeper sub-categories, the Categories table starts widening to accomodate them, and pushes the center column to the right. This makes the whole shop look unprofessional.

 

The quick fix would be to just shorten the names in the list, but that isn't possible. Is there some other way to keep that table a static size? Forcing the text to wrap would be great, but I have no clue as to how to do that.

 

Any help is appreciated.

Link to comment
Share on other sites

I do a lot of heavy customizing in OsComm and so I'm always adjusting the size of my left column.

 

So there's good news and bads news..

 

Good news is that you can control the size of your left column, forcing all text to wrap should it exceed the fixed with (ie., catagory or subcatagory names).

 

Example:

- BACKUP ALWAYS!

- Open index.php

- Find this line

 

<td width="<?php echo BOX_WIDTH; ?>" valign="top"><table border="0" width="<?php echo BOX_WIDTH; ?>" cellspacing="0" cellpadding="2">

<!-- left_navigation //-->

 

- Change

<?php echo BOX_WIDTH; ?>

 

to: what ever pixel amount you want the width to be.

 

- Find and replace on all other relevant files.

 

 

Bad News... I don't think theres a quick fix for this other than manually editing the width of the left catagories box. I've seen several contributions that deal with catagories menus, drop downs with CSS and such but have not tried this myself yet.

 

Hope this helped.

Link to comment
Share on other sites

<td width="<?php echo BOX_WIDTH; ?>" valign="top"><table border="0" width="<?php echo BOX_WIDTH; ?>" cellspacing="0" cellpadding="2">

<!-- left_navigation //-->

 

- Change

<?php echo BOX_WIDTH; ?>

 

to: what ever pixel amount you want the width to be.

Quick and easy is fine, but manual editing is fine. What exactly will I change in that statement though? I'm thinking change "BOX_WIDTH" to something like "table width="250 - is that right?

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...