3

I was using Magento 1.7 but updated to 2.0 and now this is not working...

{{block type="catalog/product_list" column_count="5" category_id="39" template="catalog/product/list2.phtml"}}

Please help

5

For magento2 you need to use class in your block while calling instead of type. Also the syntax of calling is changed.

Try below code:

{{block class="\Magento\Catalog\Block\Product\ListProduct" category_id="4" template="Magento_Catalog::product/list.phtml"}} 

Here Magento is vendor and Catalog is your module. so you need to call template with Magento:Catalog

1

You need to add below code

 {{block class="\Magento\Catalog\Block\Product\ListProduct" category_id="39" template="Magento_Catalog::product/list.phtml"}} 

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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