关于php:1.4到1.6升级后空白的自定义Magento管理模板

Custom Magento admin template blank after 1.4 to 1.6 upgrade

我有一个自定义管理模块。

site.com/index.php/admin/orderprocess/

从1.4升级到1.6后,此模块将返回空白页。 System.log给出此错误:

" 2012-01-04T19:47:01 00:00严重(2):无效的模板文件:adminhtml / base / default / template / orderprocess / item.phtml"

在Magento 1.6中,目录如下所示:app / design / adminhtml / default / cls / template / orderprocess"


您可以将default/cls/template/中的orderprocess/目录移动到app/design/adminhtml/default/default/template/。这将使Magento能够找到它。

此方法比更改您的Magento adminhtml主题名称容易得多。


请小心在后台使用的adminhtml主题的声明。根据这篇文章,您必须在模块config.xml中声明要用于管理员的主题。

但是,如果您在多个模块中有多个这种类型的声明,则可能会遇到麻烦,因为仅会使用magento会解析的最后一个主题。

在我的情况下,我在两个模块中有两个不同的主题声明,这导致了错误"无效的模板文件"。