我经常在日志中看到这个错误:
Deprecated function: Methods with the same name as their class will not be constructors in a future version of PHP; views_many_to_one_helper has a deprecated constructor in require_once() (line 127 of C:\...\sites\all\modules\contrib\ctools\ctools.module).这对我来说并不重要,我不想让它填满看门狗。有什么简单的方法可以告诉看门狗不要记录这些错误?我可以在哪里更改哪些错误被看门狗记录?
发布于 2017-01-27 12:01:37
Drupal看门狗包含PHP引发的错误,如您提到的错误。
可以使用钩子_看门狗过滤某些错误。但是,更改settings.php文件上的PHP错误级别似乎更容易,这样PHP就不会抱怨您的ctools模块。
settings.php文件上的错误级别的一些指导:https://www.drupal.org/docs/7/creating-custom-modules/show-all-errors-while-developinghttps://drupal.stackexchange.com/questions/226778
复制相似问题