0

i want to call my custom siderbar on product detail page only below is code i am using in admin > categroy > custom design

<reference name="left">
      <block type="core/template" name="Designer Sidebar"  template="page/design/sidebar.phtml"/>
</reference>

but it add sidebar on all pages how to restrict it for product detail page only as now my custom sidebar also show on product listing page i do not want it there

based marius answer i update my code to below:in admin > category > custom design

<catalog_product_view>
<reference name="left">
      <block type="core/template" name="Designer Sidebar"  template="page/design/sidebar.phtml"/>
</reference>
</catalog_product_view>

but after that i do not see sidebar.phtml there

1
  • are use using a 2columns-left as template for the page? Otherwise the left column isn't used at all
    – Jeroen
    Commented Mar 29, 2015 at 13:15

1 Answer 1

3

You can restrict it to the product pages by entering the xml in the layout update section of each product (but that's wrong and time consuming) or you can add this in one of your layout xml files:

<catalog_product_view>
    <reference name="left">
      <block type="core/template" name="Designer Sidebar"  template="page/design/sidebar.phtml"/>
    </reference>
</catalog_product_view>
1
  • pls check my updated question Commented Mar 23, 2015 at 6:21

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.