我只是尝试添加addtional模板文件以在右侧栏中包含一块内容但是失败了.
以下是我的努力
添加到local.xml文件中
<reference name="right">
<block type="cms/template" name="right.side.template">
<action method="setTemplate">
<template>callouts/right_template.phtml</template>
</action>
</block>
</reference>
Run Code Online (Sandbox Code Playgroud)
我也尝试过这个
<block type="cms/template" template="callouts/right_template.phtml"/>
Run Code Online (Sandbox Code Playgroud)
并创建了一个模板文件callouts/right_template.phtml.
但它没有在右侧栏中加载模板文件内容.
我该怎么办?我已经清除了magento缓存.
我自己发现我使用了错误的类型type="cms/template".这应该是type="core/template"
<block type="core/template" template="callouts/right_template.phtml"/>
Run Code Online (Sandbox Code Playgroud)