How to return a JSON response from a controller in Magento 2
Below, we describe how to return a JSON response from a controller in Magento 2. Continue Reading
Below, we describe how to return a JSON response from a controller in Magento 2. Continue Reading
It is possible to get base directory programmatically in Magento 2 the same way as you do it in 1.x, since it is available in the constant
To load categories by their IDs in Magento 2, Dmitry Fedyuk recommends the following: Continue Reading
In case you are looking for Magento 2 JavaScript validators, below we have them listed in a table. Continue Reading
If you don;t know how to load subcategories for a particular category in Magento 2, you’ve come to the right place. Below, we will explain this procedure. Continue Reading
To let a Magento 2 extension add a custom attribute to customers, use the following code: Continue Reading
In Magento 2, there is an app/code/Magento/Customer/view/base/ui_component/customer_form.xml file with array of buttons. Create Order Button is also there: Continue Reading
In Magento 2, do not modify CSS files within pub/* or vendor/* directories, because pub is for deployment and vendor is for default structure. Instead: Continue Reading
system.xml saved config validation in Magento 2 is possible via attaching a backend model to the field and validating the value server side. Continue Reading
To create customer groups programmatically in Magento 2, use $group->save() on the model returned by the GroupFactory: Continue Reading