I created a featured products slider on the home page. It was inserted via the following code:

{{block type="catalog/product_list" category_id="563" template="catalog/product/featured-products.phtml"}}

There are 24 products in the given category. They are showing up on the front end when you navigate to the featured-products.html category, but they are not all showing up for the static block on the home page. It seems they are not all in the collection. When I echo the following variable I get a 9, not a 24. I have reindexed and cleared cache. Any ideas?

<?php $_collectionSize = $_productCollection->count() ?>

1 Answer 1


Sounds like paging.

Are you sure, that you removed the toolbar and that the standard-limit is 9?

You can check it here:

System > Configuration > Catalog > Catalog > Shop > Items per Page (?)

  • I have only the german version here at the moment :-/ And I'm not sure whether this is an extension.

And you can have a look into Mage_Catalog_Block_Product_List_Toolbar there is the limit set.

  • How do I get all products in collection without changing the item per page limit. I want to keep the limit on the front end, but display all the products in my slider. Commented Jul 24, 2013 at 22:51
  • Nevermind I used this tutorial to figure it out net.tutsplus.com/tutorials/php/magento-for-designers-part-6. Used this instead $cat_id = "563"; $_productCollection = Mage::getResourceModel('catalog/product_collection') ->addAttributeToSelect(array('name', 'price', 'small_image', 'short_description'), 'inner') ->addCategoryFilter(Mage::getModel('catalog/category')->load($cat_id)); Commented Jul 25, 2013 at 15:14
  • great :-) On this question on stackoverflow R.S. recommends to use limit as a parameter. I didn't find any hint in the code that this might work :-) stackoverflow.com/a/15281192/1480397 But if you have time ,try. Commented Jul 25, 2013 at 15:16

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.