How to add custom layout handle to category in Magento 2
In order to add a custom layout handle to category page, a (basic) Magento 2 module with these additional files and their content is needed:
events.xml file to “subscribe” to the event and say which observer should be fired ↵
2. An observer that adds a new layout handle to the page ↵
3. A layout file that adds needed changes to the page ↵
Session depersonalization in Magento 2, why and how?
Most likely, at least once you faced the issue when customer session does not work except an account page etc. And usually, it’s not obvious why. Is it a bug? No, actually that is the case when it’s not a bug, it’s kind of feature.
How to add the details for cart item in Magento 2
In this blog post, I would like to share a pretty interesting and not obvious solution on how to join some additional details to cart item block on checkout cart page.
Let’s say we need to add the “Brand” custom product attribute and show its value within a specific block on the product view page and checkout cart page. It’s very simple in the scope of the product page, but how to deal with number cart items on checkout cart page. There are a couple of issues which you may face with. We will cover them further.
Alternative way of adding tabs to the Magento product page
In our previous article we have discussed how to add tabs to the product page. After Magento 1.9 has been released people started asking how to handle the product page tabs since the previous method caused different troubles. The reason is in the modern RWD theme, which goes out of the box with Magento 1.9. It uses slightly different method for adding tabs than in the previous versions. So, let’s review how you can easily add own tabs on the product page for RWD-based themes in Magento CE 1.9.
Prevent JS and CSS caching during deployment
Hi guys, as you know, while moving changes to the production server very often we need to flush CSS or JS cache on the client’s side, as without this action clients will see broken design or, in case with JS cache, might get broken functionality. Therefore, we guess it is a good idea to describe how to prevent JS/CSS caching.
How to insert your block into any place in Magento
Hello guys, it’s time to tell you how to insert block into any place you want in Magento. As you know, very often we need to set some block into selected weird place without editing template, so we’ll try to describe the way how to do this using layouts and observers.
Advices and Best Practices for Magento developers
I think everyone who is interested in ecommerce development get familiar with Magento earlier or later. It’s a very popular platform, where a lot of modern programming technologies are used. Since Magento is one of the most powerful and flexible shopping cart engines, it requires a deep level of expertise to develop extensions or even do some basic changes. So we’ve decided to share our tips for Magento Developers in this article. [Continue to Part 2]
AJAX requests in Magento
AJAX is a great technology that is used to improve user experience and avoid page reloads, but how can you use it in your own Magento modules? Let’s explore…
1) You should either create a controller, for example: Namespace/YourModule/controllers/AjaxController.php or create a new action in an existing controller