This question already has an answer here:
- Get the checkbox value php 2 answers
An SQL query returns id associated with a product. Using these results a checkbox is created for each result. e.g. <input type="checkbox" name="Apply[]" value="$row["id"]">. Here $row["id"] is id of each product returned by query. What i want is to select some checkboxes and then clicking on submit button should store the value of selected checkbox in database.
I tried using arrays as mentioned by some users for storing dynamic values but it stores only 0 as a result irrespective of whatever i select.
Is there a possible way to do this via PHP and HTML only or can this be done by GET or POST method ?
Aucun commentaire:
Enregistrer un commentaire