title: MySQL order by error in PHP
body: <p>I'm making a simple cms system for a site I'm making for non-tech users to edit...  </p>
  
  <p>So far so good but when I try and run this code I keep getting: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ''pages' ORDER BY 'pages'.'pageOrder' ASC LIMIT 0 , 30' at line 1</p>
  
  <p>By the error it looks like a problem with the order by section and indeed it works without it...</p>
  
  <pre><code>$sql = "SELECT * FROM 'pages' ORDER BY 'pages'.'pageOrder' ASC LIMIT 0 , 30";
  
  $result = mysql_query($sql) or die(mysql_error());
  </code></pre>
  
  <p>Now I know there is nothing wrong with the code because originally I wrote my own SQL but then after it failed I robbed some from phpmyadmin and it still gives the error but it works in phpmyadmin...  </p>
  
  <p>I'm really at my wits end with this, help is very much appreciated thank you...</p>