HOME ➔ SUPPORT ➔ Community ➔ General CourseLab issues ... Action On closing window
Action On closing window
  View type:
Hi,

Just something probably quite simple. I have a course that shows a certificate on completion if they click a button on the page. Some of the users however close the window using the exit button or the X, and they never get to see the certificate. Is there a way of checking when they close the window and if the status is complete to open a window with the certificate?

Thanks in advance
 
I would start googling for 'javascript onunload' as in
<body onunload="exitPage();">

Anyhow, this means after publishing you have to edit the published start.html and either add some javascript functions or a small external library.

Somewhere on this forum there is a thread about jumping to a page using javascript.

Another, simpler, solution might be to show the certificate immediatly after completion of the course.[:)]
 
 
Have the window open for the module without the windows close button. Of course you'd have to add your own exit button but there are advantages.
For example you could add an 'are you sure pop' up before the module is finally closed, and for your certificate problem a 'open the certificate page before closing' pop up.
Then again ou might not think it worth the effort LOL
Subject:
Message options
No additional options