mercredi 29 avril 2015

Checkbox and database

I am displaying certain items and its value from the database in the form of check boxes. So the check box will be checked if the value of the item is true, else the check box is unchecked. At the same time, I am taking input from the same check boxes.

So if the user wants to check any check box, they can do so. Ans if they want to uncheck any check box, the similar changes should get reflected in the database.

How do I implement this in php. I just need to know how can I take the value from the check box which are unchecked by the users, because they appear marked as I have used checked='checked', and the corresponding value will always stay 1.




Aucun commentaire:

Enregistrer un commentaire