javascript - using Change on an Input and then modifying the input's ATTR? -


given:

html

<input checked="checked" class="list_completed_checkbox" id="list_item_completed" name="list_item[completed]" type="checkbox" value="1"> 

jquery:

$('.list_completed_checkbox').change(function() {     $(this).attr('disabled', 'disabled'); }); 

when check or uncheck checkbox, why isn't disabled attr being applied input?

thanks

your code works me:

http://jsfiddle.net/jasongennaro/qye96/

perhaps else interfering?


Comments

Popular posts from this blog

c# - SharpSVN - How to get the previous revision? -

c++ - Is it possible to compile a VST on linux? -

url - Querystring manipulation of email Address in PHP -