Useful tips for everyday
How do I redirect a controller? Use this: return RedirectToAction(“LogIn”, “Account”, new { area = “” }); This will redirect to the LogIn action in…
How do you override a plugin function? You can’t really “override” a function. If a function is defined, you can’t redefine or change it. Your…
How are Magento 2 repositories related to the module? Magento 2 repositories are part of the domain logic of a module. That means, there is…
How do I create a login? The Do’s Keep it clear. You can’t go wrong with a simple login form and clean design. Distinguish login…
Do you have to install Magento before running commands? Before you run any of these commands, you must either install the Magento application or enable…
How to customize view models in Magento 2? If a view model is required to be a new instance each time, you must add the…
Why do I get uncaught TypeError in Magento 2? I ran into this when a custom module links js in the html head from an…
How to save Data in quote item in Magento2? $quoteItems = $this->cart->getItems(); foreach ($quoteItems as $eachQuoteItem) { $eachQuoteItem->setCustomname(‘aaaa’); $eachQuoteItem->setIsSuperMode(true); $eachQuoteItem->save(); }; How do you update…
Where do you enter coupon code in Magento? For example, a coupon code can be created for a specific customer group, or for anyone who…
When to migrate Magento from 1.9.x to 2.3? If you are still using Magento 1, even when it’s updated to the latest Magento 1.9.4.1, there…