mysql - What is my error in php code -


what error in php code, following error, hope help

warning: mysqli_num_rows() expects parameter 1 mysqli_result, boolean given in c:\xampp1\htdocs\blog\blog.php on line 45

because aren't supplying code, can't tell... error occurs when query invalid, resulting in "false" (thus boolean). in query, use mysqli_error(), example:

mysqli_query($link, "select * blabla bla=3") or die(mysqli_error($link)); 

don't forget remove "or die " after debugging, because it's cheap way of displaying error.


Comments

Popular posts from this blog

php - How to display all orders for a single product showing the most recent first? Woocommerce -

asp.net - How to correctly use QUERY_STRING in ISAPI rewrite? -

angularjs - How restrict admin panel using in backend laravel and admin panel on angular? -