jquery - Can not disable checkbox by value -


here code not working.checkboxes created dynamically.i want disable checkboxes values "undefined"

var val = "undefined"; $('#dynamiccapability').on('input:checkbox[value="' + val + '"]').attr('disabled', true); 

it says undefined when value empty,try this:

$('input:checkbox[value=""]').prop('disabled', true); 

Comments

Popular posts from this blog

How to access named pipes using JavaScript in Firefox add-on? -

multithreading - OPAL (Open Phone Abstraction Library) Transport not terminated when reattaching thread? -

node.js - req param returns an empty array -