Prestashop PHP Smarty错误

问题描述

我的error_log文件不断充满此错误,我不知道是什么原因引起的。我知道如何找到导致错误的原因吗?

[14-Aug-2020 13:20:32 Europe/Bucharest] PHP Fatal error:  Uncaught  --> Smarty: 0():Missing '$template' parameter <-- 
  thrown in /home/website/public_html/vendor/smarty/smarty/libs/sysplugins/smarty_internal_templatebase.PHP on line 177

解决方法

这意味着在代码中的某个地方存在一个未定义的名为{$template}的变量。可能是主题模板或模块 我将使用IDE查找此变量。如果这样不起作用,那就去调试技术,从smarty开始渲染开始,直到崩溃的地方:)

对于这个问题,它似乎是重复的,也许会有所帮助

SmartyException 0():Missing '$template' parameter with Prestashop

,

这也可能是由于混乱的模块结构,其ModuleFrontControllers等导致的。

您可以尝试编辑此文件:

thrown in /home/website/public_html/vendor/smarty/smarty/libs/sysplugins/smarty_internal_templatebase.php on line 177

并检查是否可以记录有关错误,文件路径等的更多信息。