title: mysql update from array. what do i miss?
body: <p>i use a mysql wrapper class to gather datas from form. i need to update a mysql text field called "accommodation" with a string from a loop like that:</p>
  
  <pre><code>foreach($_POST['postcode'] as $index =&gt; $cp)
  
      {
          $cp = $cp; 
          $name = $_POST['name'][$index];
  
          $insert = "$cp,$name;";
  
      }
  
  $data['accommodation'] = $insert;       
  
  $db-&gt;update("circuits_".$_POST['year']."", $data, "type='".$tour."'");
  </code></pre>
  
  <p>if i echo $insert inside the loop everything is fine, i have my complete string. but i need to update the database outside the loop to have the all string. and yet i gather only the last value of the array, not the all string. thanks for your help.</p>