<?xml version="1.0" encoding="utf-8"?>
<!DOCTYPE wml PUBLIC "-//WAPFORUM//DTD WML 1.1//EN" "http://www.wapforum.org/DTD/wml_1.1.xml">
<wml>
<head><meta forua="true" http-equiv="Cache-Control" content="max-age=0" /></head>
<card title="PHP Deprecated: Assigning the return value of new by reference is deprecated php 5.3版本及以上出错" id="card1">
<p> 游客</p><p>
标题:PHP Deprecated: Assigning the return value of new by reference is deprecated php 5.3版本及以上出错<br/>
正文:<br/>
php程序当php的版本升级到5.3以后，会出现”Deprecated: Assigning the return value of new by reference is deprecated in“　显示出来。这是因为5.3以后，不能使用”=&amp;amp;”符号，可以直接用”=”就可以了。所以当出现这个问题后有两种解决方法：1.　把php的版本降级到5.3以下，但后退的不是明智的选择。2. 　对程序中”=&amp;amp;”符号全部用”=” 代替。<br/> 示例如下：<br/>Deprecated: Assigning the return value of new by reference is deprecated in定位到出错的那一行：1  $this-&amp;gt;_ole =&amp;amp; new OLERead(); 我本地环境用的是PHP/5.3.8。下面这段话引用于因思而变解决办法：php5.3开始后，废除了php中的”=&amp;amp;”符号，所以要想复制，直接用=引用即可。详细如下：1、PHP5对象复制是采用引用的方式；<br/>2、如果不采用引用方式，则需要在复制对象时加关键字 clone;<br/>3、如果在复制的过程中，同时要变更某些属性，则增加函数_clone();<br/><a href="http://camnpr.com/wap.asp?mode=WAP&amp;act=View&amp;id=1013&amp;Page=1">[&lt;&lt;]</a><a href="http://camnpr.com/wap.asp?mode=WAP&amp;act=View&amp;id=1013&amp;Page=1">[[1]]</a><a href="http://camnpr.com/wap.asp?mode=WAP&amp;act=View&amp;id=1013&amp;Page=1">[&gt;&gt;]</a><br/>
<br/>
<a href="wap.asp?act=Com&amp;id=1013">查看评论(0)</a><br/>
<a href="wap.asp?act=AddCom&amp;inpId=1013">发表评论</a><br/><br/>

<br/>

<br/>
<a href="http://camnpr.com/wap.asp">首页</a>
</p>
</card>
</wml>