while遍历结果集for遍历。$num=mysql_num_rows($result);for($i=0;$i<$num;$i++){ $row=mysql_fetch_assoc($result); $arr[]=$row;}while的条件怎么填- -。 貌似我好像见过。貌似忘了。------解决方案--------------------while($row=mysql_fetch_assoc($result)){ $arr[]=$row;}