I am using Ajax to load a popup containing different settings, including a button ("click" event) and some radio buttons ("change" event).
While the "click" event works fine, (using the following function)
$("#my_popup").on("click", '.my_button', function() {  
   "use strict";
   // do some things
});
... the "change" event does not. See the corresponding function below:
$('#my_popup').on('change', 'input[name=input_name]:radio', function(){
  "use strict";
  if(condition) {
    // do some other things
  } else {
    // do some other things
  }
});
Any ideas how to make this work? According to the dynamic event binding rules in this thread I believe it should be working fine...
HTML:
<div id="my_popup">    
  <input id="radio_1" type="radio" name="input_name">
  <input id="radio_2" type="radio" name="input_name">
  <!-- [...] -->
</div>
Thanks in advance.
 
    