operation with all inputs, without type=“checkbox”

2020-08-02 02:48发布

问题:

I want to do some operation with input elements in td. I used for this:

            var inputElements = $('td > input', row);

            inputElements.each(function () {

               //some operation

            });

How can I except checkboxes?

回答1:

Get all inputs in each cell, except checkboxes.

var inputElements = $('td > input:not(:checkbox)', row);