View Single Post
  #19  
Old 07-12-2010, 07:39 AM
 
Sisom Sisom is offline
 

eXpert
  
Join Date: Sep 2006
Posts: 310
 

Default Re: Why are they still using tables for layout?

Well, I found a simpler solution, I edited the CSS for
products_list.tpl

and changed line 2745 of main.css to:

Code:
.products-list .item { position: relative; margin: 0px 0px 45px 10px; background: #FFEEEE; padding: 10px; border: 2px solid red; float: left; width: 330px; height: 300px; }

That reduces the width of the (normally one column wide) product box, and floats it to the left, so you end up with two columns, and a LOT less work than trying to completely rewrite products_t.tpl.
You MUST give the element a height, otherwise the height may vary (for example, if the item has been reviewed, it will say "You have rated this product already", which adds height to the box) - and then you will suffer from the dreaded 'float drop', and you'll find your product boxes higglegy piggledy down the page...


All it means is that the customer can't choose to have one or three columns by editing General Settings, Appearance Options, 'Display products list in multiple columns (1-3) (leave empty to use standard format)', but that wouldn't work with my design anyway.
__________________
X-Cart Gold Version 4.3.2
Reply With Quote