I've developed a CakePHP
application, based on version 2.3.0
. The app was working on a server with PHP 5.3.3-7
version.
Now, the app has been moved to new environment, with PHP 5.4.34-1
version and it throws fatal error:
Error: include(): Cannot redeclare class debugger File: /home/html/directory/lib/Cake/Core/App.php Line: 560
Does anyone have a clue, what could cause this problem? I know what such problem means (that I cannot redeclare a class), but I don't know how to fix it.
I know this is an old question, but since this coincided with moving to PHP v. 5.4, a likely fix is changing your Error level in the core.php file from
'level' => E_ALL & ~E_DEPRECATED,
to this
'level' => E_ALL & ~E_DEPRECATED & ~E_STRICT,
PHP 5.4 includes E_STRICT in the E_ALL set, unlike previous versions.