I am trying to create a very simple and basic search script.
Here is what I have done so far:
include('config.php');
$search_token =$_POST['search_token'];
$search_query = mysqli_query($conn, "SELECT Forname FROM idea WHERE post_des LIKE '%$search_token%'");
while($row = mysqli_fetch_array($search_query))
{
$idea_body = $row['post_des'];
echo $idea_body;
}
But when I execute this, I am having the following Warning:
Warning: mysqli_fetch_array() expects parameter 1 to be mysqli_result, boolean given in F:\Server\xampp\htdocs\p\c3\search.php on line 34
Any help for this situation?