Magento – where is declared layout xml file in module

extensionslayoutmagento-1.9module

i am learning to create a module from here.

http://devdocs.magento.com/guides/m1x/magefordev/mage-for-dev-4.html

And on in this article everything is fine even workin also but i want to know where local.xml file is declared.

app/design/frontend/base/default/layout/local.xml


When i call this action method how it know that it have to load template from layout/local.xml. why it did not try to load template from other xml file?

public function call_blockaction() {
//remove our previous echo
//echo 'Hello Index!';
$this->loadLayout();
$this->renderLayout();
}

Best Answer

local.xml is only used as part of your custom theme and should not be used when creating a module. If you have your own layout instructions use something like

<config>
    <frontend>
        <layout>
            <updates>
                <fooman_example>
                    <file>fooman_example.xml</file>
                </fooman_example>
            </updates>
        </layout>
    </frontend>
</config>

and then create the file app/design/frontend/base/default/layout/fooman_example.xml