Welcome to our blog!

Magento 2 tutorial

Blog for Magento 2

Menu

Category: Magento 2

Magento tutorials for developers.


Magento 2: newsletter subscribe by ajax

January 23, 2020 at 2:09 pm | Magento, Magento 2 | arpit kumar -

In this tutorial we learn how to use plugin in magento 2. In below code we create a plugin to make a ajax hit for newsletter subscription for users rest of all setting are same as default magento provides. Di.xml New Controller extended from Magento\Newsletter\Controller\Subscriber\NewAction newsletter_subscripe.phtml (Override it for core newsletter_subscripe.phtml) formsubmitnow.js file for Ajax

Continue reading…

“Magento 2: newsletter subscribe by ajax”

Magento 2: how to call .phtml file from CMS Page

January 19, 2020 at 2:04 pm | Magento, Magento 2 | arpit kumar -

Hello Friends, In this atrtical we learn how to call .phtml file from cms page, layout file and another .phtml file. From CMS Page {{block class=”Magento\Bannerslider\Block\Slideshow” template=”Magento_Bannerslider::bannerslider.phtml”}} From another .xml file From another .phtml

Get Base Url in Magento 2

January 17, 2020 at 12:26 pm | Magento, Magento 2 | admin -

In Magento 1, its very easy just use code: Mage::getBaseUrl(); But in Magento 2 There are 2 ways to get Base Url. Object Manages Magento Core Method Object Manages Magento Core Method