Totally Zenned
- Join Date:
- May 2006
- Location:
- Gardiner, Maine
- Posts:
- 2,383
- Plugin Contributions:
- 7
Not actually a bug per se but a long term problem that I have a solution to.
Ongoing issue with zen cart listing boxes has always been the width of the containers at a percent - 3 in a row, width is 33%. That means you can never add in padding or borders and mods have been created to fix that. I have looked at all sorts of ways to deal with it in the new code and came up with a possible solution.
I made one change to the code in tpl_listingbox_columnar_default.php:
echo $tplVars['listingBox']['formattedItems'][$row][$col]['colWidth'] - 2; ?>%">
I subtracted 2 from the width so that the box width becomes 31% instead.
The I can pad the boxes and add a smidge to push then further to the right:
.centerBoxContentsFeaturedIndex, .centerBoxContentsSpecialsIndex, .centerBoxContentsNewIndex {
padding: 8px 5px; margin-left: 1px;
} // and also purchased as well whatever the class name is
No padding needed on the rest of the box which now has the images butting up against the center content heading.
This way makes it way easier to style the contents of those boxes or add borders and make each box separate as some mods do now.
This can be changed from 2 to larger numbers to accommodate more padding, margins and borders for styling without having to resort to mods. Um, this is minor but really important to a designer.
The full-time Zen Cart Guru. WizTech4ZC.com
New template for 2.0 viewable here: 2.0 Demo