cancel
Showing results for 
Search instead for 
Did you mean: 

How to use Ajax for the newsletter subscription in Magento 2

   Did you know you can see the translated content as per your choice?

Translation is in progress. Please check again after few minutes.

How to use Ajax for the newsletter subscription in Magento 2

Hi everybody, I am Cuong, Welcome back to my Magento 2 tutorial video series.

 

Today, I am going to show everybody the best practice, How to use Ajax for the newsletter subscription in Magento 2.

 

By default, Magento 2 provides us with a module called Magento_Newsletter, that allows the customer to subscribe to the newsletter by submitting the form showing on the footer. However, when the customer submits the form, the current page must be reloaded, this is not good.

 

To improve the experience of the customer avoiding reloads the current page, we use the Ajax for submitting the form.

See the video about this tutorial here https://www.youtube.com/watch?v=6zlSJ6hYgBY&list=PL98CDCbI3TNvPczWSOnpaMoyxVISLVzYQ&index=43

 

 

 

How to use Ajax for the newsletter subscription in Magento 2.png

 

Screenshot_1.png Screenshot_2.png