这是我的代码:
$sql= ("SELECT R.cr_id,R.time,R.reply,U.user_id,U.user_name FROM tb_user U, conversation_reply R WHERE R.user_id_fk=U.user_id and R.c_id_fk='$c_id' ORDER BY R.cr_id ASC LIMIT 20");
$stmt = $conn->prepare($sql);
$stmt->execute();
$row=$stmt->fetchAll();
foreach ($row as $laww) {
echo $laww['$user_name'].":". $laww['reply']. "<br>";
}
}////END
我只得到$ laww ['reply']的结果,但不是$ laww ['$ user_name'] 谁能帮助我?