0

Is there way that i could identify where a radio option value gets changed, either thru watch expression on firebug or inspect element ?

i am remote debugging a website and there are 4 radion buttons in the website. We set the CHECKED property for my 4th option as true, it gets checked. But after a sometime(1 sec) my first option gets selected automatically. There are too many javascript code involved and i am not sure where to check. So is there any way i can do a debug-BREAK when a watch expression fires or any other way to debug this?

consoleart
  • 151
  • 8
  • I think this can help : http://stackoverflow.com/questions/8838648/onchange-event-handler-for-radio-button-input-type-radio-doesnt-work-as-one – Mehran Torki Feb 11 '16 at 17:18
  • http://stackoverflow.com/questions/2518421/jquery-find-events-handlers-registered-with-an-object – mplungjan Feb 11 '16 at 17:20

1 Answers1

0

You can do this using jquery:

$('input[type=radio][name="inputName"]').on('change',function(){

    //#myForm is the id of the form that the radio box in
    alert($('input[name="inputName"]:checked', '#myForm').val());

});

This will alert the new value of the radio box when changed JsFiddle

Marox Tn
  • 142
  • 9