There are a number of related/similar/same questions, but none of them have helped me find the solution.
I have a HTML table wrapped in a form. For each row in the table, there is a hidden row with the form controls for editing. I don't need to submit the whole form as it would include all values for all cells. So, using AJAX, I want to submit only the values for a single row. To do this, I have given each row an id attribute, then using jQuery I hook the row's submit button and retrieve the values for that row.
The problem is, neither .serialize() nor .serializeArray() return anything. Yet, all the controls have names and values. And, as far as I can tell, there is no problem with the DOM structure.
Here is a fiddle reproducing the problem.
Can anybody point out the problem or suggest a way to get the name value pairs without having to loop the controls?
Aucun commentaire:
Enregistrer un commentaire