If radio button is check display a textbox Jquery

前端 未结 5 731
北海茫月
北海茫月 2021-01-28 03:08

Hey Ya\'ll I have got a question with my radio buttons I have these 3 buttons

No  
         


        
5条回答
  •  渐次进展
    2021-01-28 03:49

    $("input[type='radio']").change(function(){
    
       if($(this).val()=="other")
       {
          $("#otherAnswer").show();
       }
       else
       {
           $("#otherAnswer").hide(); 
       }
    
    });
    

    Here is the working example : http://jsfiddle.net/Wc2GS/8/

提交回复
热议问题