Index: branches/5.2.x/core/admin_templates/incs/close_popup.tpl =================================================================== --- branches/5.2.x/core/admin_templates/incs/close_popup.tpl +++ branches/5.2.x/core/admin_templates/incs/close_popup.tpl @@ -69,10 +69,16 @@ } var $frameset = $main_window.parent.frames; + for ($i = 0; $i < $frameset.length; $i++) { - if ($frameset[$i].name == $name) { - return $frameset[$i]; - } + try { + if ($frameset[$i].name == $name) { + return $frameset[$i]; + } + } + catch ( e ) { + // Foreign domain frame detected. + } } return $main_window.parent; } @@ -107,4 +113,4 @@ - \ No newline at end of file + Index: branches/5.2.x/core/admin_templates/js/script.js =================================================================== --- branches/5.2.x/core/admin_templates/js/script.js +++ branches/5.2.x/core/admin_templates/js/script.js @@ -1436,8 +1436,13 @@ var $frameset = $main_window.parent.frames; for ($i = 0; $i < $frameset.length; $i++) { - if ( $frameset[$i].name == $name ) { - return $frameset[$i]; + try { + if ($frameset[$i].name == $name) { + return $frameset[$i]; + } + } + catch ( e ) { + // Foreign domain frame detected. } } @@ -1942,4 +1947,4 @@ }, 1000); } ); -} \ No newline at end of file +}