1

I have to change the results per page option on my products page. The results per page drop down must show 3,12,21 and right now it's 12,24,36. I have to change it using only the local.xml file. I'm using magento 1.9.

4
  • Cannot you change from admin area? Any reason for changing it from local.xml? Commented Dec 12, 2016 at 0:15
  • yes i could but I was assigned to do it from the local.xml because I'm doing an internship and they told me to do it that way so I would learn the "proper way". Just a weird request from them..
    – Rufas
    Commented Dec 12, 2016 at 0:26
  • Well I changed it from the admin area, I'll ask them tomorrow how I was supposed to do it. Thanks for the help anyway!
    – Rufas
    Commented Dec 12, 2016 at 0:29
  • Check this: magento.stackexchange.com/questions/34451/… too., Commented Dec 12, 2016 at 0:34

1 Answer 1

1

you can try this code may it works

   <reference name="product_list_toolbar">
        <block type="page/html_pager" name="product_list_toolbar_pager"/>
              <action method="setDefaultListPerPage"><limit>4</limit></action>
                        <action method="setDefaultGridPerPage"><limit>9</limit></action>
                        <action method="addPagerLimit"><mode>list</mode><limit>3</limit></action>
                        <action method="addPagerLimit"><mode>list</mode><limit>6</limit></action>
                        <action method="addPagerLimit"><mode>list</mode><limit>9</limit></action>
                        <action method="addPagerLimit"><mode>list</mode><limit>12</limit></action>
                        <action method="addPagerLimit" translate="label"><mode>list</mode><limit>all</limit><label>All</label></action>
        </block>
   </reference>

Add above code in category handler those are

<catalog_category_default>

and

<catalog_category_layered>

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

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