Forum Discussion
johnfaulkes
4 years agoCommunity Member
Publish to Flash first to get JS email working??
Trying to get the JS email function to work, I have created a javascript trigger with the simplest possible code, to start an email from SL 360. I tried pasting in the exact code from the help pages...
WaltHamilton
4 years agoSuper Hero
I'm baffled by this, because the scripts are separate scripts, and should not effect one another, but, as they say, "The compiler is what the compiler does."
The third script has a line break after questionnaire, and a mismatched " in the body_start variable.
Here is a version I got to work for me.
var email="john.faulkes@gmail.com";
var subject="Report requested";
var player = GetPlayer();
var body_start="here is a more comprehensive report on this questionnaire"+ player.GetVar("leader_role")+ player.GetVar("effective_communication");
var mailto_link='mailto:'+email+'?subject='+subject+'&body='+body_start;
window.location.href = mailto_link;