I have a page with many tutorial terms and explanations on it. There is a checkbox on each for the user to indicate that they have read the tutorial for that term.
<input type="checkbox" class="ios-switch green bigswitch" value="10|1234">
When they check the checkbox, I need to send the value (which has the tutorial_id and the member_id packed) and the status (checked or unchecked), using PHP, to write to the tutorial_completed table.
But on uncheck, I need to send the same value pair and the stutus, unchecked, to delete the entry from the database.
All the methods I have tried have failed. I tried a few options here, but none worked with sending both the values and the checked and unchecked status in both cases.
Is there an elegant way to do this in real time?
Aucun commentaire:
Enregistrer un commentaire