题
我是 magento 的新手。我正在使用magento版本 1.9.0.1
我想使用我的自定义模块在主页中调用自定义 phtml。我不想更改 CMS 页面。
我怎样才能做到这一点?
解决方案
如果您已经创建了一个块,您可以在主题 xml 中使用它将其添加到主页,或者如果您的模块中有一个布局 xml 文件,请将其放入其中。
<cms_index_index>
<reference name="content">
<block type="core/template" name=""your_template" template="your_template.phtml" />
</reference>
</cms_index_index>