Forum Discussion
Stephanie
12 years agoSuper Hero
User notes that they can print and email
Hi all. I built a course earlier this year that contains a "notes" function to allow users to take a moment to reflect and type their thoughts on certain questions. This is used in place of a typica...
DaveGalvin
9 years agoCommunity Member
Hi Matthew,
That is great. I adjusted the script as below and all works as hoped.
var player = GetPlayer();
var email = 'my.email@address.com'
var fbk = player.GetVar('Feedback');
var fbk2 = player.GetVar('Feedback2');
var fbk3 = player.GetVar('Feedback3');
var subject = 'Course Feedback';
var emailBody = 'Here is some feedback:' + '\n' + fbk + '\n' + fbk2 + '\n' + fbk3;
var mailto_link = 'mailto:' + email + '?subject=' + subject + '&body=' + encodeURIComponent(emailBody);
win = window.open(mailto_link, 'emailWin');
Two quick questions if I may:
- Will this work in a LMS?
- Is there a way of stopping a blank tab opening at the same time as the email?
Thanks again Matthew!
Regards
David
Related Content
- 9 months ago
- 7 months ago
- 8 months ago
- 9 months ago
- 12 months ago