Friday, 31 May 2013

Calling the list page and toolbar in any cms page in magento || call the category product in cms page in magento

It can also show the products of perticular category.

Go to admin->cms->page->design(layout Xml)

Put this code to layout Xml tab:

<reference name="content">
<block type="catalog/product_list" name="home" template="catalog/product/list.phtml">
<action method="setCategoryId"><category_id>137</category_id></action>

<action method="addColumnCountLayoutDepend"><layout>one_column</layout><count>5</count></action>
<block type="catalog/product_list_toolbar" name="product_list_toolbar" template="catalog/product/list/toolbar.phtml">
<block type="page/html_pager" name="product_list_toolbar_pager"/>
 </block>
<action method="setToolbarBlockName"><name>product_list_toolbar</name><count>5</count></action>
</block>
 </reference>

No comments:

Post a Comment