Error when running php code
侠骨丹心
侠骨丹心 2021-03-06 20:24:40
0
1
1137

Warning: mysqli_query() expects at least 2 parameters, 1 given in D:\phpstudy_pro\WWW\allusers.php on line 31Warning: mysqli_num_rows() expects parameter 1 to be mysqli_result, null given in D:\phpstudy_pro\WWW \allusers.php on line 33

The following is the code

//Query all data in the data table

$result=mysqli_query("SELECT * FROM users BY id DESC ");

//Get the number of data items in the data table

$dataCount=mysqli_num_rows($result);

//echo $dataCount;

//Print out all data

侠骨丹心
侠骨丹心

reply all(1)
灭绝师太

mysqli_query() receives two parameters, the first parameter is the MySQL connection

Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template