Monday 18 July 2016

magento 2 call newsletter in sidebar

add below code in <body> tag in module-newsletter/view/frontend/layout/default.xml

<referenceContainer name="sidebar.additional">
            <block class="Magento\Newsletter\Block\Subscribe" name="form.subscribe" as="subscribe" after="wishlist_sidebar" template="subscribe.phtml"/>

        </referenceContainer>

Note :- You can use sidebar.main instead of sidebar.additional  for show in top of sidebar.

No comments:

Post a Comment