Tip: Click lines to highlight, hold ctrl/cmd to multi-select
radioChange (10-Sep @ 16:12)
Works both with checkboxes and radio buttons.
Syntax Highlighted Code
- $.fn.radioChange = function (fn) {
- return this.each(function () {
- if (!$.browser.msie) {
- $(this).change(fn);
- } else {
- $(this).click(fn);
- }
- });
- };
Plain Code
$.fn.radioChange = function (fn) {
return this.each(function () {
if (!$.browser.msie) {
$(this).change(fn);
} else {
$(this).click(fn);
}
});
};