title: PHP Echo Table formatting. 3rd column to appear under row 1. Is it possible with Echo?
body: <p>I am using PHP to pull back data from within MySQL. My basic web page and query is working ok for the most part. I am using echo to dump the results out to a table on screen. The code is as follows:</p>
  
  <pre><code>      foreach ($dbh-&gt;query($sql) as $row){ 
            echo "&lt;tr&gt;"; 
            echo "&lt;td'&gt;".$row['DATAA']."&lt;/td&gt;"; 
            echo "&lt;td'&gt;".$row['DATAB']."&lt;/td&gt;"; 
            echo "&lt;td'&gt;".$row['DATAC']."&lt;/td&gt;";
            echo "&lt;/tr&gt;"; 
        } 
        $sql-&gt;closeCursor();
  </code></pre>
  
  <p>I would like to do some slightly advanced formatting of the tables as follows:</p>
  
  <p><img src="https://i.imgur.com/TyvWw.jpg" alt=""></p>
  
  <p>Does anyone know if this is possible with the PHP Echo command? </p>
  
  <p>I am having problems finding suggestions around the internet, due to PHP and HTML tables vs MySQL tables and rows and columns all getting mixed up on search results. </p>
  
  <p>So any help or code samples would be appreciated.</p>