Hi,
I have done a search, but can't seem to apply any of the suggestions to my specific case... I am somewhat of a newbie, so please excuse my ignorance...
I am trying to insert multiple values from checkboxes into one table column...
here is the code I have:
<?php $sql = "INSERT INTO survey1 (name,email,bestsellers) VALUES ('$name','$email','$bestsellers')";
// run SQL against the DB
$result = mysql_query($sql);?>
<p><strong>Jewelry Buying Survey</strong></p>
<form name="survey_says" method="post" action="<?php echo $PHP_SELF?>">
<input type="checkbox" name="bestsellers[]" value="Gold"> Gold<br>
<input type="checkbox" name="bestsellers[]" value="Silver"> Silver<br>
<input type="checkbox" name="bestsellers[]" value="Leather"> Leather<br>
<input type="checkbox" name="bestsellers[]" value="Gemstones"> Gemstones<br>
<input type="checkbox" name="bestsellers[]" value="Costume/Bridge"> Costume/Bridge<br>
<input type="checkbox" name="bestsellers[]" value="Earrings"> Earrings<br>
this is just a small piece of a fairly large form. the result i get from the above code is simply "Array" in the bestsellers column.
anyone be able to update my code so this works right? also, how would i then display it on my results page?
thanks!