错误:以$ sql开头
<?php
$sql = mysql_query("SELECT `sub_id` FROM `subject_studant` WHERE `std_id` = 2 ") or die mysql error();
while($row=mysql_fetch_assoc($sql))
{
$sub_id1 = $row['sub_id'];
echo $sub_id1;
}
?>
答案 0 :(得分:4)