Magento – Magento configurable swatches on product list in custom theme

configurable-productmagento-1.9swatches

I'm trying to get configurable swatches to work in my own custom theme, and have followed these instructions: How to use Magento 1.9.1.0 Configurable Swatches in Default package theme (or a custom theme)?

This works for the product page, but I don't get the swatches showing up in the list view.

The rwd catalog xml file has this entry:

<catalog_category_layered translate="label">
<reference name="content">
    <block type="catalog/category_view" name="category.products" template="catalog/category/view.phtml">
        <block type="catalog/product_list" name="product_list" template="catalog/product/list.phtml">
            <block type="core/text_list" name="product_list.name.after" as="name.after" />
        </block
    </block
</reference>
</catalog_category_layered>

if I add in:

<block type="core/text_list" name="product_list.name.after" as="name.after" />

To my base theme catalog.xml file in the same spot it works, so what do I put in my theme's xml file to get this to work the same? How do I target the block called product_list to add that core/text_list block into it?

Best Answer

To make it work you need to add

<block type="core/text_list" name="product_list.name.after" as="name.after" />
<block type="core/text_list" name="product_list.after" as="after" />

after

<block type="catalog/product_list" name="product_list" template="catalog/product/list.phtml">

in catalog.xml under catalog_category_layered section and copy

app\design\frontend\rwd\default\template\catalog\product\list.phtml

to your theme

Related Topic