【发布时间】:2013-05-31 11:46:42
【问题描述】:
为什么这段代码有效:
$row = $stmt->fetch();
$result = array("status"=>"0", "uid"=>($row["id"]));
而这个没有:
$result = array("status"=>"0", "uid"=>(($stmt->fetch())["id"]));
【问题讨论】:
-
抱歉重复,感谢您的回答。
-
@ValentinSolina 没问题。感谢 15 位代表接受 ;)