文章给大家介绍在使用ecshop时提示Strict Standards: Only variables should be passed by reference in错误问题解决办法。 ecshop提示Strict Standards: Only variables should be passed by reference in E:/Tools/ECShop_V2.7.3_U

文章给大家介绍在使用ecshop时提示Strict Standards: Only variables should be passed by reference in错误问题解决办法。

ecshop提示Strict Standards: Only variables should be passed by reference in错误  ecshop Standards 第1张

ecshop提示Strict Standards: Only variables should be passed by reference in

E:/Tools/ECShop_V2.7.3_UTF8_release1106/upload/includes/cls_template.php

on line 418

这个错误,搜索问题原来是php版本的问题,我是用的php5.4版本的,解决办法如下:

只要418行把这一句拆成两句就没有问题了

代码如下 复制代码
$tag_sel = array_shift(explode(' ', $tag));
改成:
$tag_arr = explode(' ', $tag);
$tag_sel = array_shift($tag_arr);

(实验过,绝对可行) 因为array_shift的参数是引用传递的,5.3以上默认只能传递具体的变量,而不能通过函数返回值

转载请说明出处
知优网 » ecshop提示Strict Standards: Only variables should be passed by reference in错误

发表评论

您需要后才能发表评论