我的页面上有一张表格,表格的每一行都应被批准为是或否,并且可以编辑或删除这些行以修改/删除各个列中的值。check the image attached here单击“是/否”,每行的“批准”列应显示是“是”还是“否”,如果不是两者,则应显示“是”,“否”按钮。
点击是/否按钮时出现以下错误
Commands out of sync; you can't run this command now.
Warning: mysqli_num_rows() expects parameter 1 to be mysqli_result, boolean given in line 517
错误来自以下查询,
514 $SQL = "SELECT * FROM table WHERE deleted=0 AND Id=".$Id;
515 $rs = mysqli_query($link,$SQL);
516 if ($rs == false) echo "Error". mysqli_error($link);
517 if(mysqli_num_rows ($rs)==1) $lastrow=1;
514-517是行号