:::: MENU ::::

Magento certification: Register layout XML files

4.20 avg. rating (80% score) - 5 votes

How can layout XML files be registered for the frontend and adminhtml areas?

In Magento, you may register a new Layout XML file with layout updates by adding this piece of XML to your module config.xml

<layout>
  <updates>
    <anyuniquename>
      <file>nv/homelayout.xml</file>
    </anyuniquename>
  </updates>
</layout>

If you need the layout file to apply to the Magento frontend, you’ll need to add to the section <frontend> of your config.xml file. If you want it to apply to the Magento backend, you need to add to the section <adminhtml>, and if you the layout file to apply both to the frontend and to the backend, you may add it to the <global> section.




Hey! Qué opinas sobre el artículo?