title: MySQLi/PHP Search engine doesn't work
body: <p>So far I have this...  </p>
  
  <pre><code>&lt;html&gt;
  &lt;head&gt;
  &lt;title&gt;Search&lt;/title&gt;
  &lt;/head&gt;
  &lt;body&gt;
  &lt;form method="GET"&gt;
  &lt;input type="text" size="30" /&gt;
  &lt;/form&gt;
  
  &lt;?php  
  $db = "example";  
  
  mysqli_connect("localhost","root","*************");  
  mysqli_select_db($db);  
  $query = mysqli_query("SELECT * FROM TABLE WHERE search_query = '$q'");  
  mysqli_query($query);
  $results = mysqli_fetch_array($query);
  
  if($results !=="") {
  echo "&lt;a href='$array[0]'&gt;Result 1&lt;/a&gt;";
  echo "&lt;a href='$array[1]'&gt;Result 2&lt;/a&gt;";
  // you get the idea
  }
  ?&gt;
  &lt;/body&gt;
  &lt;/html&gt;
  </code></pre>
  
  <p>I am wondering why MySQLi is not returning what I searched in the bar. I inserted data into the database manually... it's just not working</p>