我想在PrestaShop中重写一个控制器
<?php
class ProductController extends ProductControllerCore{
public function initContent()
{
parent::initContent();
}
public function init()
{
parent::init();
echo "datbase";
die;
}
}
?>包含我的覆盖的文件位于:
projectname/override/controllers/front/ProductController.php
但是我的超驰不起作用。
发布于 2015-08-06 20:45:34
好的,我现在是通过研究一些东西得到的
我找到了解决方案:
您应该删除缓存文件夹中的class_index.php文件。
发布于 2019-05-31 08:17:05
PrestaShop 1.7.x的更新答案
在PrestaShop 1.7.x版本中,class_index.php文件现在位于/var/cache/prod中

别忘了删除这个文件,以防你刚刚添加了一个新的覆盖,否则它不会工作。
我希望这能帮到你!
https://stackoverflow.com/questions/31855867
复制相似问题