Like when you click on the checkbox to send the form data via ajax?

Is a form of filter, it is necessary that when you click on one of the fields of this filter sent data to server and returning the number of products with such parameters.
But I don't know how many fields it might be a hundred, maybe two.

How to send form data via ajax all at once?
And that page was not reloaded.

Thank you.
July 2nd 19 at 17:46
1 answer
July 2nd 19 at 17:48
Solution
All fields must wrapped(inside) any one block or shape, or something else. Or another option, all fields can specify a single class. Then do a search of all fields(input,select, or what have you) inside the unit, or class appropriately.
For example, something like:
var fields = $('div.fields').find('input[type=text], select');
document.forms[formId].elements not so cool?) - Karlie.Ki commented on July 2nd 19 at 17:51
: Yes, different cool only idea suggested, the rest of the author's case - hubert56 commented on July 2nd 19 at 17:54
Thank you!) - Carolina15 commented on July 2nd 19 at 17:57

Find more questions by tags AJAXjQuery