title: help with php FOREACH loop
body: <p>can some please tell me what's wrong with the bellow foreach php loop.</p>
  
  <pre><code>foreach ($_POST[sortlist] as $key =&gt; $value) 
  {
      $sql = "UPDATE sortable 
              SET color_order = " . mysql_real_escape_string($key) . " 
              WHERE id = " . mysql_real_escape_string($value);
  
      $result = mysql_query($sql) or die(mysql_error());
  }
  </code></pre>
  
  <p>I keep getting warning: invalid argument suplied foreach() in ....
  when i upload to server</p>
  
  <p>Thanks</p>