click or change event on radio using jquery

后端 未结 5 1607
挽巷
挽巷 2021-02-06 19:49

I have some radios in my page,and I want to do something when the checked radio changes,however the code does not work in IE:

$(\'input:radio\').change(...);
         


        
5条回答
  •  太阳男子
    2021-02-06 20:41

    Try

    $(document).ready(
    

    instead of

    $('document').ready(
    

    or you can use a shorthand form

    $(function(){
    });
    

提交回复
热议问题