失眠网,内容丰富有趣,生活中的好帮手!
失眠网 > strict standards php报错 Bigcommerce:PHP版本升级错误解决办法_PHP教程

strict standards php报错 Bigcommerce:PHP版本升级错误解决办法_PHP教程

时间:2024-01-25 19:26:35

相关推荐

strict standards php报错 Bigcommerce:PHP版本升级错误解决办法_PHP教程

报错内容一:Strict Standards: Declaration of....should be

compatible with .....

Strict Standards: Declaration of ISC_CHECKOUT_PROVIDER::GetPropertiesSheet() should be compatible with ISC_MODULE::GetPropertiesSheet($tab_id, $idGlobal, $jsGlobal, $jsSelectedFunction, $customVars = Array, $moduleId

= NULL) in /home/ipcamera/public_html/includes/classes/class.checkoutprovider.php on line892

报错的意思:子类重写的父类的函数,子类函数里面的参数与父类的参数不对应

查看文件class.checkoutprovider.php报错的892行,GetPropertiesSheet()函数如下:

public function GetPropertiesSheet($tabId, $doHeaderRows=true, $moduleId=''){

.....

}

解决方法:把GetPropertiesSheet()函数的参数改为父类中的参数,其实直接Copy报错提示的信息就可以啦~

更改后:

public function

GetPropertiesSheet($tabId, $idGlobal, $jsGlobal, $jsSelectedFunction, $customVars = Array(), $moduleId = NULL)

{

.....

}

报错内容二:Strict Standards: Non-static method....should

not be called statically in .....

Strict Standards: Non-static method ISC_REDIRECTS::generateRedirectUrl() should not be called statically in/home/ipcamera/public_html/lib/class.redirects.php on line30

报错的意思:generateRedirectUrl()函数是非静态声明,他不可以被静态(static)声明的方法调用

查看文件class.redirects.php报错的30行,GetPropertiesSheet()函数如下:

publicstatic function checkRedirect($urlPath)

{

// @codeCoverageIgnoreStart

$newUrl = self::generateRedirectUrl($urlPath);

.....

}

public function generateRedirectUrl($urlPath)

{

.....

}

解决方法:把generateRedirectUrl()函数改为静态声明

更改后:

public static function generateRedirectUrl($urlPath)

{

.....

}

报错内容三:Strict Standards: mktime(): You should be using the time() function instead in.....

Strict Standards: mktime(): You should be using the time() function instead in/home/ipcamera/public_html/lib/general.php on line

3590

报错的意思:mktime()方法不带参数被调用时,会被抛出一个报错提示

查看文件general.php报错的3590行,如下:

$args = func_get_args();

$result = call_user_func_array("mktime", $args);

解决方法:mktime()方法改为time()方法

更改后:

$args = func_get_args();

$result = call_user_func_array("time", $args);

/PHPjc/621622.true/PHPjc/621622.htmlTechArticle报错内容一: Strict Standards : Declaration of....should be compatible with ..... Strict Standards : Declaration of ISC_CHECKOUT_PROVIDER::GetPropertiesSheet() should be comp...

本条技术文章来源于互联网,如果无意侵犯您的权益请点击此处反馈版权投诉

本文系统来源:php中文网

如果觉得《strict standards php报错 Bigcommerce:PHP版本升级错误解决办法_PHP教程》对你有帮助,请点赞、收藏,并留下你的观点哦!

本内容不代表本网观点和政治立场,如有侵犯你的权益请联系我们处理。
网友评论
网友评论仅供其表达个人看法,并不表明网站立场。