简体   繁体   English

Joomla 1.5.x网站可用于PHP 5.3,但不适用于PHP 5.6

[英]Joomla 1.5.x website works with PHP 5.3 but does not work with PHP 5.6

I tried to run my Joomla 1.x website with PHP 5.6 and got the following errors: 我尝试使用PHP 5.6运行Joomla 1.x网站,并收到以下错误:

Strict Standards: Declaration of KHttpUri::set() should be compatible with KObject::set($property, $value = NULL) in /home/beauty/www/libraries/koowa/http/uri.php on line 0 Strict Standards: Declaration of KHttpUri::get() should be compatible with KObject::get($property = NULL, $default = NULL) in /home/beauty/www/libraries/koowa/http/uri.php on line 0 Strict Standards: Non-static method JLoader::register() should not be called statically in /home/beauty/www/libraries/joomla/cache/cache.php on line 19 Strict Standards: Declaration of JCacheStorage::get() should be compatible with JObject::get($property, $default = NULL) in /home/beauty/www/libraries/joomla/cache/storage.php on line 0 Strict Standards: Non-static method JLoader::register() should not be called statically in /home/beauty/www/libraries/joomla/document/document.php on line 19 Strict Standards: Non-static method JLoader::import() should not be called statically in /home/beauty/www/libraries/loader.php on line 186 Strict Sta 严格标准:KHttpUri :: set()的声明应该与/home/beauty/www/libraries/koowa/http/uri.php上第0行严格标准中的KObject :: set($ property,$ value = NULL)兼容:KHttpUri :: get()的声明应与/home/beauty/www/libraries/koowa/http/uri.php中第0行严格标准中的KObject :: get($ property = NULL,$ default = NULL)兼容:第19行上的/home/beauty/www/libraries/joomla/cache/cache.php中不应静态调用非静态方法JLoader :: register()严格标准:JCacheStorage :: get()的声明应兼容在第0行的/home/beauty/www/libraries/joomla/cache/storage.php中使用JObject :: get($ property,$ default = NULL)严格标准:非静态方法JLoader :: register()不应在第19行的/home/beauty/www/libraries/joomla/document/document.php中静态调用严格标准:非静态方法JLoader :: import()不应在/ home / beauty / www / libraries /中静态调用第186行严格STA上的loader.php ndards: Non-static method JLoader::import() should not be called statically in /home/beauty/www/libraries/loader.php on line 186 Fatal error: Call-time pass-by-reference has been removed in /home/beauty/www/plugins/content/listitems.php on line 95 ndards:非静态方法JLoader :: import()不应在第186行的/home/beauty/www/libraries/loader.php中静态调用致命错误:/ home中的调用时传递引用已被删除/beauty/www/plugins/content/listitems.php,第95行

The website worked fine before with PHP 5.3 (on Ubuntu 12.X LTS), so probably this is something related to compatibility PHP 5.3/5.6. 在使用PHP 5.3(在Ubuntu 12.X LTS上)之前,该网站可以正常工作,因此,这可能与PHP 5.3 / 5.6的兼容性有关。

Does anyone know what is it? 有谁知道这是什么吗? What PHP extension this can relate to? 这可以涉及什么PHP扩展?

It is pointless to tinkering with such an old Joomla version and get it run with a php 5.6. 修补这样一个旧的Joomla版本并使其与php 5.6一起运行是毫无意义的。 Joomla 1.5.x is not compatible with PHP 5.4 nor with 5.6; Joomla 1.5.x与PHP 5.4或5.6不兼容; it's old but still available: docs.joomla.org/Joomla_1.5_won't_work_on_PHP_5.4 . 它很旧,但仍然可用: docs.joomla.org/Joomla_1.5_won't_work_on_PHP_5.4 Nevertheless, the library koowa is not part of Joomla itself; 但是,库科瓦图书馆不是Joomla本身的一部分; you could rename the declarations of your classes, rename all functions which are called static (ie JLoader::register()) to a static function, etc. But you are still working with unsecure old libraries/plugins/components and Joomla version. 您可以重命名类的声明,将所有称为静态的函数(即JLoader :: register())重命名为静态函数,等等。但是您仍在使用不安全的旧库/插件/组件和Joomla版本。 Maybe you've changed the error reporting somewhere else (.htaccess), and you should have a look at http://php.net/manual/en/appendices.php . 也许您已经更改了错误报告的其他位置(.htaccess),并且应该看看http://php.net/manual/en/appendices.php You should better migrate your site to the latest Joomla3.7.4 and PHP7... By the way, Call-time pass-by-reference has been removed in /home/beauty/www/plugins/content/listitems.php on line 95 which can be solved like in PHP 5.4 Call-time pass-by-reference - Easy fix available? 您最好将您的站点迁移到最新的Joomla3.7.4和PHP7 ...顺便说一句, Call-time pass-by-reference has been removed in /home/beauty/www/plugins/content/listitems.php on line 95可以像在PHP 5.4中那样通过调用时传递引用来解决-可以轻松修复吗? , usually the function call works without the @ . ,通常函数调用不使用@。 Please also specify the exact version of Joomla (in your question please), between 1.0 and 1.5 as well as 1.7 are huge differences! 请同时指定Joomla的确切版本(请在您的问题中),介于1.0和1.5以及1.7之间是巨大的差异!

These are only strict and standard warnings, so you can just set the global config param debug to none and all warnings will be gone. 这些只是严格和标准的警告,因此您只需将全局配置参数调试设置为none,所有警告都将消失。

Better would it be to check the code and manually fix it for PHP 5.6 handling - no developer will give you support for Joomla!v1.5 anymore, so you have to fix it on your own. 最好是检查代码并手动修复它以进行PHP 5.6处理-不再有开发人员会为您提供对Joomla!v1.5的支持,因此您必须自己对其进行修复。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM