Hi everyone, I have an issue posting an array from check boxs, simply put i have a database that contains some details, i want to take these details, split them into an array and therefore separate check boxs then a user will select a number of check box and then this will be saved as an array into a seperate table, hope i explained that ok.

So here is the code I have some far, I have some code elsewhere for the $result part, and for the submit part, but basically its grabs the information from a table and splits it into check boxs (in theory) the "label" part works, i have this here to check that its is getting the right information and it is, the problem happens when I submit the form, it will only save the last checked check box, so if i click say check box 1,3,5 (there could be an unlimited amount of options which is why im pulling the data from another table) and these values are One, Three, Five only Five will save in the table.

PHP Code:
<?php foreach ( $results['detailsline'] as $detailsline ){
$invoice_details $detailsline->details_line;
echo 
'<label>'.$invoice_details.'</label><input type="checkbox" name="invoice_details" value="'.$invoice_details.'"/>';   
 }                  
?>
If I have explained this well enough can someone guide me please.

Ian