0

Am working on Magento 1 Store

I want to show only new products of particular category on a page. Suppose i have category of shirts so i want to show only 8 new products of that category on page.

i tried to use this block to show only category products but its not respecting the product limit.

{{block type="catalog/product_list" column_count="8" category_id="43" template="catalog/product/list.phtml"}}

1 Answer 1

0

Try this code:

{{block type="catalog/product_list" category_id="CATEGORY_ID" template="catalog/product/list.phtml" column_count="5" products_count="10"}}

Note : Replace CATEGORY_ID with numeric category id.

2
  • Thanks for help sir, but on frontend product count is not being respected as it shows all the products of that category. Jun 11, 2018 at 7:23
  • can you add this code on you phtml <?php $_productCollection=$this->getLoadedProductCollection(); $_helper = $this->helper('catalog/output'); $_productCollection->clear()->setPageSize($this->getData('products_count'))->load(); ?>
    – user68116
    Jun 11, 2018 at 7:40

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.