Skip to main content
Known Participant
July 9, 2015
Question

Why is the function DoCPExit() added to multiscreen.html causing course to close automatically? How can we avoid it publishing?

  • July 9, 2015
  • 1 reply
  • 462 views

I have some courses that launch on the LMS and automatically close.  I am removed the code below, and  the course behave normally.  What is the purpose of this function?  Where in the publish settings do they go to add or delete this function? Before I advise them to just erase it , Id like to be able to explain why.

function DoCPExit()
  {
   if(window != window.parent && window.parent && window.parent.hasOwnProperty("DoCPExit"))
   {
    window.parent.DoCPExit();
   }
   else
   {
    if(window.top == self)
    {
     var win = window.open("","_self");
     win.close();
    }
    else
    {
     var win = window.top.open("","_self");
     win.top.close();
    }
   }
  }

  function IsRunningInConnect()
  {
   if(!document.location || !document.URL || !document.referrer)
     return false;
   return (document.location.href.indexOf("airspeed") != -1 || document.URL.indexOf("airspeed") != -1 || document.referrer.indexOf("airspeed") != -1)
  }

This topic has been closed for replies.

1 reply

RocwonAuthor
Known Participant
October 26, 2015

Having the same issue.  Have you found out why this function  exist and how to change the publish settings?