title: How to display table data in reverse? (php)
body: <p>I have simple code for displaying images. I created table with 4 columns (ID, location, capture, equence) and inserted there 18 records. My question is: how to display all records from table in reverse mode? I need to make that the last entry will be displayed first, and the first entry displayed last.</p>
  
  <p>What I need: 18-1
  What I have now: 1-18</p>
  
  <p>I was searching for simple codes to do that, but notwing worked at all. So i'd be very grateful if someone will help me to solve that problem.</p>
  
  <p>Heres the basic code of my display script:</p>
  
  <hr>
  
  <pre><code>&lt;?php
  
  mysql_connect("localhost", "***", "***") or die(mysql_error());
  mysql_select_db("martinidb1337") or die(mysql_error());
  
  $result = mysql_query("SELECT * FROM klpgalerija") or die(mysql_error()); while($row = mysql_fetch_array( $result )) {
  
      echo '&lt;p&gt;&lt;img src="'.$row['location'].'"&gt;&lt;/p&gt;';
  }
  </code></pre>
  
  <hr>