MDL-53546 SCORM: Set window.opener to null

This commit is contained in:
Dan Marsden 2016-03-30 10:03:25 +13:00 committed by Andrew Nicols
parent fc1ef59fbe
commit d4f96fa397
2 changed files with 3 additions and 0 deletions

View File

@ -23,6 +23,7 @@ function scorm_openpopup(url,name,options,width,height) {
options += ",width=" + width + ",height=" + height;
windowobj = window.open(url,name,options);
windowobj.opener = null;
if (!windowobj) {
return;
}

View File

@ -83,6 +83,7 @@ M.mod_scormform.init = function(Y) {
winobj = window.open(launch_url,'Popup', poptions);
this.target = 'Popup';
scormredirect(winobj);
winobj.opener = null;
}
// Listen for view form submit and generate popup on user interaction.
if (scormform) {
@ -91,6 +92,7 @@ M.mod_scormform.init = function(Y) {
winobj = window.open(launch_url, 'Popup', poptions);
this.target = 'Popup';
scormredirect(winobj);
winobj.opener = null;
e.preventDefault();
}, scormform);
}