Drupal How to add javascript to ctools modal popup
You must use: ctools_ajax_command_attr('selector','attr','value'); do perform any kind of actions in popup. For more you can read: http://drupalcontrib.org/api/drupal/contributions!ctools!includes!ajax.inc/7