title: mysqli_query() expects at least 2 parameters, 1 given in?
body: <p>I keep getting the same 3 errors every time I run this php. I have no clue what I am doing wrong, can anyone help?</p>
  
  <p>Here are the errors:</p>
  
  <blockquote>
    <p>[05-May-2014 19:20:50 America/Chicago] PHP Warning:  mysqli_query()
    expects at least 2 parameters, 1 given in
    /home/sagginev/public_html/Nutrifitness/search.php on line 10</p>
    
    <p>[05-May-2014 19:20:50 America/Chicago] PHP Warning:  mysqli_num_rows()
    expects parameter 1 to be mysqli_result, null given in
    /home/sagginev/public_html/Nutrifitness/search.php on line 11</p>
    
    <p>[05-May-2014 19:20:50 America/Chicago] PHP Warning:  mysqli_num_rows()
    expects parameter 1 to be mysqli_result, null given in
    /home/sagginev/public_html/Nutrifitness/search.php on line 16</p>
  </blockquote>
  
  <p>here is my code </p>
  
  <p><code>enter code here</code> </p>
  
  <pre><code>    &lt;?php
      $con=mysqli_connect('localhost','sagginev_rob','122989','sagginev_Nutrifitness');
      if (mysqli_connect_errno()) // Check connection
        {   echo "Failed to connect to MySQL: " . mysqli_connect_error();  }
  
          if(!isset($_POST['search'])) {
      header("Location:home.php");
      }
      $search_sql="Select * FROM Questions WHERE username LIKE '%".$_POST['search']."%' OR feedback LIKE '%".$_POST['search']."%'";
      $search_query=mysqli_query($search_sql);
      if(mysqli_num_rows($search_query)!=0) {
      $search_rs=mysqli_fetch_assoc($search_query);
      }
      ?&gt;
      &lt;H2&gt; Search Results&lt;/H2&gt;
      &lt;?php if(mysqli_num_rows($search_query)!=0) {
       do { ?&gt;
       &lt;p&gt;&lt;?php echo $search_rs['name']; ?&gt; &lt;/p&gt;
      &lt;?php } while ($search_rs=mysqli_fetch_assoc($search_query));
      } else {
         echo "No results found";
      } ?&gt;
      &lt;form&gt;
      &lt;br&gt;
      &lt;input type="button" value="Go Back Home" onClick="parent.location='http://sagginevo.com/Nutrifitness/home.php'"&gt;
      &lt;/form&gt;
  </code></pre>