Is there an actual way to handle the columnCount in Magento's 1.9 RWD theme?
It is not possible to use addColumnCountLayoutDepend
in layout.xml
to set the column counts depending on the page layout in this theme and is only used to set the maximum columns.
I can manually set $_columnCount = 2;
in the list.phtml
and whilst $_columnCount;
outputs 2, the columns on the front end don't actually change.
I see that the widths (%) for the <li>
items are all hardcoded in styles.css
to 4 decimal places – surely there is a way to handle this without altering all the widths in the stylesheet to get the amount of products per row you want in your grid?
Even if it were a case of altering all the widths, how do you get this perfect with 4 decimal places like so:-
width: 30.8642%;
margin-right: 3.7037%;
I'm sure I must be overlooking something else?
Best Answer
To set the column count for a particular category, select that category in the backend under Manage Categories. Then select the Custom Design tab—here, add in the following code and modify as needed: