Instead of passing hardcoded values, we can dynamically get these values and pass them to the XML using {{baseUrl}} variable.
In today’s tutorial, we will see how we can remove/disable add to compare functionality from all places in Magento 2. There is no configuration setting to remove the “Product Compare” feature in Magento2. But we can use the remove=”true” attribute in our theme’s custom layout file and remove/disable add to compare related reference blocks. we …
Hello Devs, In this tutorial we are going to explore Magento 2 UI components and we will see how we can Show/Hide one field based on another field in UI Component forms in Magento 2. We often face the requirement of having a field dependent on the value of another field in our UI form. …
In this tutorial, we will see, how we can remove layout blocks using PHP programmatically instead of working in the layout.xml file in Magento 2. I have already shown how to Remove Blocks or containers from Layout in Magento 2?, but in some cases, you will need to remove blocks using dynamic conditions. In that case, …
Magento provides flexibility to update page designs as per business requirements to improve customer experience. As a part of this, we may be required to remove blocks or containers from specific layout files in Magento. In Magento 2 layouts, you can easily remove a specific block or container using the magical “remove” attribute. You can …
In Magento 2, we can use ifconfig in layout XML for the block to display or not based on the Magento / Config / Model / Config / Source / Yesno configuration field by using the ifconfig argument.