Thursday, 27 June 2013

How I chenged checkbox bg color on when it is checked?

Your are not setting the color on the label but on the checkbox. jQuery makes it easy for you to select / traverse DOM elements (and also helps clean-up a lot of unnecessary IDs), see this fiddle :
        $(this).parent().css('backgroundColor', '#bff0a1');
        $(this).parent().css('backgroundColor', '#eee');        
Live Example