Magento:通过“自定义布局更新"进行产品特定设计 [英] Magento: product specfic designs through 'Custom Layout Update'
本文介绍了Magento:通过“自定义布局更新"进行产品特定设计的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
如果我想控制每种产品的显示方式(即指定时的自定义设计),我的首要想法是:
If I want to control how each product is displayed (i.e. a custom design when specified) my first thought is to do this:
- 在template/catalog/product/ my_view.phtml 中创建自定义 view.phtml
- 在管理员中导航至产品->设计->自定义布局更新
- 添加此块:
- Create a custom view.phtml in template/catalog/product/my_view.phtml
- Navigate in the admin to Product->Design->Custom Layout Update
- Add this block:
<reference name="content">
<action method="setTemplate">
<template>catalog/product/view_print.phtml</template>
</action>
</reference>
但是模板从不加载,只有默认的view.phtml.这是正确的方法吗?我需要能够在产品设置中执行此操作.
But the template is never loaded, only the default view.phtml. Is this the correct method? I need to be able to do this in the product settings.
推荐答案
找到了答案:
<reference name="product.info">
<action method="setTemplate"><template>catalog/product/NEW_VIEW.phtml</template></action>
</reference>
这篇关于Magento:通过“自定义布局更新"进行产品特定设计的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文