Magento set limit for products


Below code will call limit products with function getLoadedProductCollection().
Here, I use function setPageSize() and I set a variable is numbers of products need to show.

I get an example is file template/catalog/product/list.phtml in default of Magento Enterprise

Add after this line code in template/catalog/product/list.phtml:


By this code:


After, clear all cache, reload and see result


Have a nice day!

About Author

Là một developer rất ham chơi nhưng không ham hố, không ham chơi nhưng rất thích cầm đầu...

1 Comment

Leave a Reply

%d bloggers like this: