$r=Db::singleSqlRow($s);$content="userName=$r['userName']";
$r是个数组,我这样下出错了,我知道把$r['userName']先定义一个变量就可以了,能否把$r['userName']自动当成变量处理
回复讨论(解决方案)
$content="userName={$r['userName']}";
对于易引起歧义的应当用{}括起来。
$r=Db::singleSqlRow($s);$content="userName=$r['userName']";
$content="userName={$r['userName']}";
对于易引起歧义的应当用{}括起来。
本文是由用户编写整理,所有内容的版权归原作者所有。如果侵犯了您的权益,请联系我删除