I'm trying to update a database table from a table with a list of names with an additional column with a checkbox. The user is checking the box to indicate that someone in the list attended the event.
I'm loading the view in a table format with names and a column for the checkbox.
The problem I'm having is how to identify the row of each column without displaying the id for each name in the database. If I use a hidden column for the id... it doesn't get transfered.
I am able to pass the id by adding the id to the value on the checkbox but then it comes of as an array.
If you are having multiple checkboxes with the same name attribute, then you should have an array input, e.g. name="pracid[]" if you set the value attribute to the id of the model, then whenever the form is submitted you will get an array of id's which should true.