Showing posts with label call newsletter in left sidebar using xml file in magento 2. Show all posts
Showing posts with label call newsletter in left sidebar using xml file in magento 2. Show all posts

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.