Results 1 to 9 of 9
  1. #1
    Join Date
    May 2008
    Posts
    261
    Plugin Contributions
    0

    Default sidebox layout problem

    hi, everyone,

    Does anybody know how to specify the width for one specific sidebox, such as best_seller

    seems that in Zen-cart, all the sidebox always agree to the width of $column_box_default, that is class=.leftBoxContainer or class=.rightBoxContainer, whose width can be set through Admin-->layout setting

    Now supposed i set the .leftBoxContainer and .rightBoxContainer to 170px, but i ONLY want the sidebox
    best_seller to be 200px, how to achieve this?

    Any suggestion would be appreciated.

  2. #2
    Join Date
    Nov 2006
    Location
    Dartmouth, NS Canada
    Posts
    2,378
    Plugin Contributions
    0

    Default Re: sidebox layout problem

    I'm not sure if a stylesheet change can override the settings from admin, but maybe if you set the width of that particular sidebox in the stylesheet using the !important addition to the definition, it'll work. See here for how to use !important.

    Be sure your column width is set wide enough for the 200px sidebox, or Bad Things will happen.

    Rob

  3. #3
    Join Date
    May 2008
    Posts
    261
    Plugin Contributions
    0

    Default Re: sidebox layout problem

    hi, rstevenson,

    how genious you are! really appreciated for your great answers.
    it works.

    but could you please explain further why the MAX. width is 200px?

  4. #4
    Join Date
    Nov 2006
    Location
    Dartmouth, NS Canada
    Posts
    2,378
    Plugin Contributions
    0

    Default Re: sidebox layout problem

    Well, you gave as an example of what you're trying to do...
    Now supposed i set the .leftBoxContainer and .rightBoxContainer to 170px, but i ONLY want the sidebox
    best_seller to be 200px, how to achieve this?
    If your left column was 170px wide and you tried to put a 200px wide sidebox into it, either the sidebox wouldn't be 200px wide, or -- more likely -- the column width would be forced out to 200px anyway, and that could throw off other parts of your site design if you're not expecting it.

    THIS JUST IN ...

    I decided to put it to the test. On my retail site (link below) I entered this into the stylesheet...

    #information {width: 200px !important;}

    The result was that my Information sidebox expanded right out past the borders of the left column, running right over top of text in the centercolumn area. In my case this would not be a good thing, but depending on your design, this might work for you.

    All you can do is try it and see, I guess.

    Rob

  5. #5
    Join Date
    May 2008
    Posts
    261
    Plugin Contributions
    0

    Default Re: sidebox layout problem

    hi, Rob ,

    Many thanks for your patient explanation.

    what great retails sites!!
    wonderful job.

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

    Default Re: sidebox layout problem

    In IE (older versions at least), the whole column may expand to 200px. It is not supposed to according to CSS standards, but we know about IE and standards...

  7. #7
    Join Date
    May 2008
    Posts
    261
    Plugin Contributions
    0

    Default Re: sidebox layout problem

    Hi, Glenn,

    Can not agree with you any more.

    Yes, the whole column expanded to 200 px.

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

    Default Re: sidebox layout problem

    If you use
    margin-right: -30px;
    in the individual sidebox rule, it should allow the sidebox to overrun the column edge. Sometimes this might not work in older IE either, though - depends on a hidden IE property "has_layout" which needs to be triggered.

  9. #9
    Join Date
    May 2008
    Posts
    261
    Plugin Contributions
    0

    Default Re: sidebox layout problem

    hi, Glenn,

    maybe this is the way we want.
    will try to test it.

 

 

Similar Threads

  1. v151 Adjust Featured Sidebox Layout to Match Bestsellers Sidebox Layout
    By gaffettape in forum Templates, Stylesheets, Page Layout
    Replies: 7
    Last Post: 12 Apr 2013, 03:36 AM
  2. Facebook Sidebox Layout Problem
    By Higgster in forum Addon Sideboxes
    Replies: 0
    Last Post: 9 Jul 2011, 07:45 PM
  3. Problem: layout problem with Firefox!
    By raylauhk in forum Templates, Stylesheets, Page Layout
    Replies: 3
    Last Post: 6 Aug 2010, 07:41 PM
  4. categories sidebox layout
    By ivanc in forum Templates, Stylesheets, Page Layout
    Replies: 4
    Last Post: 19 Dec 2008, 06:45 AM
  5. Problem with sidebox layout
    By JMcGov in forum Templates, Stylesheets, Page Layout
    Replies: 3
    Last Post: 27 Jun 2008, 07:02 PM

Bookmarks

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
Zen-Cart, Internet Selling Services, Klamath Falls, OR