我最近将PHPlink目录的PHP版本更新为最新版本,但是更新后,我开始出现以下错误。我立即将新版本更改为旧版本,但错误仍然存在。
PHP在5.4版上运行。
Strict Standards: Only variables should be assigned by reference in /home/domain/public_html/init.php on line 275
Strict Standards: Non-static method SmartyPaginate::connect() should not be called statically in /home/domain/public_html/index.php on line 688
Strict Standards: Non-static method SmartyPaginate::getTotal() should not be called statically in /home/domain/public_html/libs/smarty/SmartyPaginate.class.php on line 51
Strict Standards: Non-static method SmartyPaginate::getUrlVar() should not be called statically in /home/domain/public_html/libs/smarty/SmartyPaginate.class.php on line 52
Strict Standards: Non-static method SmartyPaginate::disconnect() should not be called statically in /home/domain/public_html/index.php on line 693
Strict Standards: Non-static method SmartyPaginate::reset() should not be called statically in /home/domain/public_html/index.php on line 694
Strict Standards: Non-static method SmartyPaginate::setPrevText() should not be called statically in /home/domain/public_html/index.php on line 696
Strict Standards: Non-static method SmartyPaginate::setNextText() should not be called statically in /home/domain/public_html/index.php on line 697
答案 0 :(得分:0)
我认为这与PHP版本无关。您正在调用一个正常的函数,例如它是静态的,但不是。
您可以尝试进入这里:
public static function connect() {
}
或者您可以这样调用函数:
$paginate = new SmartyPaginate;
$paginate->connect();
$paginate->getTotal();