Sending email from inside course

Apr 27, 2021

Hi All,

I'm trying to set up a "certificate of course completion" email users can send themselves from within the course. End goal: the user gets an email listing the course name and page number (pulled from variables) and asserting they have completed the course.

Has anybody pulled this off before?

Thanks,

1 Reply
Anna Michael

I found that earlier, but following (or working based on) those examples hasn't worked out for me. My most recent try is below:

var player = GetPlayer();
var email = player.GetVar('UserEmail');
var subject = 'Certificate of Course Completion';
var emailBody = 'The recipient of this email has completed ' + CourseName + '. ' +'Sent from ' + PageNumber + '.';

var mailto_link = 'mailto:' + email + '?subject=' + subject + '&body=' + encodeURIComponent(emailBody);

win = window.open(mailto_link, 'emailWin');