title: Select from Database errors
body: <p>I want to select some info from my database called Catalogonline and display it on a Html Page.But now my php code show this errors </p>
  
  <blockquote>
    <p>Warning: mysqli_select_db() expects exactly 2 parameters, 1 given in
    C:\wamp\www\insert12.php on line 14</p>
  </blockquote>
  
  <p>And </p>
  
  <blockquote>
    <p>Warning: mysqli_query() expects parameter 1 to be mysqli, string given
    in C:\wamp\www\insert12.php on line 15</p>
  </blockquote>
  
  <p>And </p>
  
  <blockquote>
    <p>Warning: mysqli_error() expects exactly 1 parameter, 0 given in
    C:\wamp\www\insert12.php on line 18  Could not get data:</p>
  </blockquote>
  
  <p>My code is   </p>
  
  <pre><code>&lt;?php
  $dbhost = 'localhost';
  $dbuser = 'Florin';
  $dbpass = '######';
  $conn = mysqli_connect($dbhost, $dbuser, $dbpass);
  if(! $conn )
  {
    die('Could not connect: ' . mysqli_error());
  }
  $sql = 'SELECT id, Username, 
                 Signup_Date, E-mail
          FROM membri';
  
  mysqli_select_db('catalogonline');
  $retval = mysqli_query( $sql, $conn );
  if(! $retval )
  {
    die('Could not get data: ' . mysqli_error());
  }
  while($row = mysqli_fetch_array($retval, MYSQL_ASSOC))
  {
      echo "Tutorial ID :{$row['id']}  &lt;br&gt; ".
           "Title: {$row['Username']} &lt;br&gt; ".
           "Author: {$row['Signup_Date']} &lt;br&gt; ".
           "Submission Date : {$row['E-mail']} &lt;br&gt; ".
           "--------------------------------&lt;br&gt;";
  } 
  echo "Fetched data successfully\n";
  mysqli_close($conn);
  ?&gt;    
  </code></pre>