0

I'm trying to limit the output of products on specific categories, i.e. I'd only like to show the first 3 products (no matter how many there actually are).

All solutions I find are to set the pager-size, but I actually need to limit the products in such a way that the layered navigation only renders for those three products.

If I try the below code (in local.xml) to set the pager-size, it does work, but whenever I try to set a limit, it doesn't. Why?

<CATEGORY_229>
  <block type="catalog/product_list">
    <action method="setLimit"><value>3</value></action>
  </block>
</CATEGORY_229>

Note: This is on a 1.6 installation

0

Try this:

<layout>
    <CATEGORY_229>
        <reference name="product_list_toolbar">
            <action method="addPagerLimit"><mode>grid</mode><limit>3</limit></action>
            <action method="addPagerLimit"><mode>list</mode><limit>3</limit></action>
        </reference>
    </CATEGORY_229>
</layout>

Note: After clear all cache in admin side

  • Yea, what this does is set the pager limit to three, it generates multiple pages. What I need is to have only 3 products as output, not 3 products per page and multiple pages. – Alex Timmer Mar 7 '17 at 10:36

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.