Results 1 to 6 of 6
  1. #1
    Join Date
    Aug 2006
    Posts
    9
    Plugin Contributions
    0

    Default subcategories layout problem

    I am not even sure how to explain the problem so I think pictures will work better.

    On my site http://www.tgtwoffroad.com if you open a category with subcategories it does this





    I have changed the max "Categories To List Per Row" and tinkered with category_row.php but I can't seem to figure out what is causing it to arrange things like this.

    Can someone help me out?

  2. #2
    Join Date
    Sep 2003
    Location
    Ohio
    Posts
    69,402
    Plugin Contributions
    6

    Default Re: subcategories layout problem

    How many across are you trying to display?

    It looks like 5 ...
    Linda McGrath
    If you have to think ... you haven't been zenned ...

    Did YOU buy the Zen Cart Team a cup of coffee and a donut today? Just click here to support the Zen Cart Team!!

    Are you using the latest? Perhaps you've a problem that's fixed in the latest version: [Upgrade today!]
    Officially PayPal-Certified! Just click here

    Try our Zen Cart Recommended Services - Hosting, Payment and more ...
    Signup for our Announcements Forums to stay up to date on important changes and updates!

  3. #3
    Join Date
    Aug 2006
    Posts
    9
    Plugin Contributions
    0

    Default Re: subcategories layout problem

    As you see it, it is set to 4 but only shows 3. I would like 3 columns. When I set it to 3 it displays 2 columns. Is there some way to adjust the spacing between the columns?

  4. #4
    Join Date
    Aug 2006
    Posts
    9
    Plugin Contributions
    0

    Default Re: subcategories layout problem

    Ok after looking at it a little more. It seems that it is putting one blank space at the end of each row or something like that.

  5. #5
    Join Date
    Jul 2005
    Location
    Upstate NY
    Posts
    22,010
    Plugin Contributions
    25

    Default Re: subcategories layout problem

    There may be some margin that is crowding the scene. If you ask for 3 per row, each is allotted 33%. Any margin could force each one to take say 35% and they wouldn't all fit.
    So you could either reduce margins (in your stylesheet) or find the PHP file where widths are assigned.

  6. #6
    Join Date
    Jun 2005
    Posts
    20
    Plugin Contributions
    0

    Default Re: subcategories layout problem

    I had the same problem. My fix for now is to override the \modules\templates_default\category_row.php file on lines 25 and 27:

    if ($num_categories < MAX_DISPLAY_CATEGORIES_PER_ROW || MAX_DISPLAY_CATEGORIES_PER_ROW == 0) {
    $col_width = floor((100/$num_categories)-3); /* Have to subtract ~3 to allow for left & right margins, otherwise coluns don't fit*/
    } else {
    $col_width = floor((100/MAX_DISPLAY_CATEGORIES_PER_ROW)-3); /* same thing here*/

    It's not elegant but it does work to get my site up and running under 1.35.

 

 

Similar Threads

  1. Categories/subcategories index image layout problem
    By prim0pyr0 in forum Templates, Stylesheets, Page Layout
    Replies: 5
    Last Post: 28 Oct 2009, 10:24 AM
  2. SubCategories & Sidebar Problem
    By trudesign in forum General Questions
    Replies: 1
    Last Post: 15 Apr 2008, 04:37 PM
  3. Inactive Subcategories Problem
    By ideasgirl in forum Customization from the Admin
    Replies: 17
    Last Post: 11 Aug 2006, 10:32 PM
  4. sidebox problem - subcategories
    By mafiasam in forum Basic Configuration
    Replies: 1
    Last Post: 11 Jul 2006, 06:59 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
disjunctive-egg