您的位置:首页 > 产品设计 > UI/UE

php5.3 中显示Deprecated: Assigning the return value of new by reference is deprecated in 的解决方法

2013-07-17 21:41 821 查看
今天需要将某个网站般去另一台服务器。设置好运行,显示一大堆Deprecated。

Deprecated: Assigning the return value of new by reference is deprecated in。

新服务器与旧服务器环境是一样的,后来查看php版本,发现旧服务器是 PHP 5.2.4 新的是PHP 5.3.2。之前了解到5.3 与 5.3之前的区别较大,于是查看php文档。



在5.3版本之后已经不允许在程序中使用"=&"符号


如果出现了Deprecated: Assigning the return value of new by reference is deprecated in 错误,

先找到出错的文件,查找下是不是在程序中使用了"=&",如发现使用了"=&"符号,将 "=&" 改成 "=" 即可解决问题。

$link =& $this->links[$linkKey];
// 改为
$link = $this->links[$linkKey];
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签: 
相关文章推荐