title: How to use bootstrap css tables to display data from MySQL tables?
body: <p>I'm trying to make it so that when a button is clicked on my main page, a php script takes action and fetches the information from the SQL tables, and displays it in a HTML/CSS table. </p>
  
  <p>Here's the code of my main page - </p>
  
  <pre><code>&lt;form id="myForm" action="select.php" method="post"&gt;
  &lt;button type="submit" class="btn btn-info" &gt;
  &lt;span class="glyphicon glyphicon-tint"&gt;&lt;/span&gt;  View
  &lt;/button&gt;
  &lt;br /&gt; &lt;span class="badge alert-info"&gt; Find out what is currently in the database. &lt;/span&gt;&lt;br /&gt;
  &lt;/form&gt;
  &lt;br /&gt;
  &lt;br /&gt;  
  </code></pre>
  
  <p>And here's what I currently have in my select.php - </p>
  
  <pre><code>&lt;?php
  /*** mysql hostname ***/
  $hostname = '192.xx.xxx.xx';
  
  /*** mysql username ***/
  $username = 'Mitchyl';
  
  /*** mysql password ***/
  $password = 'root1323';
  
  /*** database name ***/
  $dbname = 'test';
  
  try {
        $dbh = new PDO("mysql:host=$hostname;dbname=$dbname", $username, $password);
      /*** The SQL SELECT statement ***/
      $sql = "SELECT * FROM increment";
  
  }
  catch(PDOException $e)
      {
      echo $e-&gt;getMessage();
      }
  ?&gt;
  </code></pre>
  
  <p>I just don't know how to take the data from the SQL query and put it inside a HTML table. </p>
  
  <p>Any suggestions would be great! 
  Thanks!</p>