I need to display the most viewed products on home page.without any plugin installation. please help me!
Magento 1.9.1.0 – How to Display Most Viewed Products on HomePage
magento-1.9product
magento-1.9product
I need to display the most viewed products on home page.without any plugin installation. please help me!
Best Answer
Use below code to get Most Viewed products collection :
For more details, check List Popular Products
UPDATE : In admin, go to
CMS > Pages
, edit Homepage.-- In Content area, add this line :
{{block type="catalog/product" template="catalog/product/most-viewed.phtml"}}
and SAVE.-- Now create a new template file at
/app/design/frontend/PACKAGE/THEME/template/catalog/product/
, and name itmost-viewed.phtml
-- Add this code in
most-viewed.phtml
file, (this will show max 10 products, edit$totalPerPage
variable as you require)