Warning: file_get_contents(/data/phpspider/zhask/data//catemap/6/google-chrome/4.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
禁用CakePHP Beanstalk中的E_严格错误_Cakephp_Beanstalkd - Fatal编程技术网

禁用CakePHP Beanstalk中的E_严格错误

禁用CakePHP Beanstalk中的E_严格错误,cakephp,beanstalkd,Cakephp,Beanstalkd,在我将PHP升级到5.4之后,PHP抱怨E_严格。 我的VPS安装了Ubuntu 12.04。它有许多.ini文件,我已将所有错误报告更改为: error\u reporting=E\u ALL&~E\u已弃用&~E\u STRICT 我还重新启动了Apache Web服务器。 Phpinfo告诉我~E_STRICT未被阻止(错误报告=>22527=>22527) 我知道:最好的选择是更改de代码。已删除所有引用(&R) 在以下列表中,将显示日志: Strict (2048): Declarat

在我将PHP升级到5.4之后,PHP抱怨E_严格。 我的VPS安装了Ubuntu 12.04。它有许多.ini文件,我已将所有错误报告更改为:

error\u reporting=E\u ALL&~E\u已弃用&~E\u STRICT

我还重新启动了Apache Web服务器。 Phpinfo告诉我~E_STRICT未被阻止(错误报告=>22527=>22527)

我知道:最好的选择是更改de代码。已删除所有引用(&R)

在以下列表中,将显示日志:

Strict (2048): Declaration of BeanstalkdSource::create() should be compatible with DataSource::create(Model $model, $fields = NULL, $values = NULL) [APP/Plugin/Queue/Model/Datasource/BeanstalkdSource.php, line 396]

Strict (2048): Declaration of BeanstalkdSource::read() should be compatible with DataSource::read(Model $model, $queryData = Array, $recursive = NULL) [APP/Plugin/Queue/Model/Datasource/BeanstalkdSource.php, line 396]

Strict (2048): Declaration of BeanstalkdSource::update() should be compatible with DataSource::update(Model $model, $fields = NULL, $values = NULL, $conditions = NULL) [APP/Plugin/Queue/Model/Datasource/BeanstalkdSource.php, line 396]

Strict (2048): Declaration of BeanstalkdSource::delete() should be compatible with DataSource::delete(Model $model, $id = NULL) [APP/Plugin/Queue/Model/Datasource/BeanstalkdSource.php, line 396]

Strict (2048): Only variables should be passed by reference [APP/Plugin/Queue/Model/Datasource/BeanstalkdSource.php, line 382]
详情:

Strict (2048): Declaration of BeanstalkdSource::create() should be compatible with   DataSource::create(Model $model, $fields = NULL, $values = NULL) [APP/Plugin/Queue/Model/Datasource/BeanstalkdSource.php, line 396]
Code Context
if (file_exists($file)) {self::_map($file, $className, $plugin); return include $file;
App::load() - CORE/Cake/Core/App.php, line 563
App::load() - CORE/Cake/Core/App.php, line 563
spl_autoload_call - [internal], line ??
class_exists - [internal], line ??
ConnectionManager::loadDataSource() - CORE/Cake/Model/ConnectionManager.php, line 179
ConnectionManager::getDataSource() - CORE/Cake/Model/ConnectionManager.php, line 96
Model::getDataSource() - CORE/Cake/Model/Model.php, line 3245
Model::__call() - CORE/Cake/Model/Model.php, line 800
Job::put() - APP/Event/ScenarioModifiedListener.php, line 75
ScenarioModifiedListener::StartPdfScenarioJob() - APP/Event/ScenarioModifiedListener.php, line 75
ScenarioModifiedListener::StartPdfJob() - APP/Event/ScenarioModifiedListener.php, line 58
call_user_func - [internal], line ??
CakeEventManager::dispatch() - CORE/Cake/Event/CakeEventManager.php, line 248
ScenarioModifiedBehavior::afterSave() - APP/Model/Behavior/ScenarioModifiedBehavior.php, line 84
ObjectCollection::trigger() - CORE/Cake/Utility/ObjectCollection.php, line 132
call_user_func - [internal], line ??
CakeEventManager::dispatch() - CORE/Cake/Event/CakeEventManager.php, line 248 

我也尝试过更改PLESK中的设置,但没有任何结果。代码解决方案是:更改方法的签名。它应该是:更新(Model$Model,…){….ini的问题仍然存在,但目前不可见;-)更正签名是最干净和最能证明未来的方法通常:)