Story line Variables troubles

Hi Everyone.

I am having trouble with calling a number of variables in my JavaScript, see javascript below:

var player = GetPlayer();

var email=new Array();

email[0]=player.GetVar("emailadd");

var subject="Onboarding results";

var player = GetPlayer();

var body_start=new Array();

body_start[0]=player.GetVar("w1t");

body_start[1]=player.GetVar("w1q1");

body_start[2]=player.GetVar("w1a1");

body_start[3]=player.GetVar("w1q2");

body_start[4]=player.GetVar("w1a2");

body_start[5]=player.GetVar("line");

body_start[6]=player.GetVar("w2t");

body_start[7]=player.GetVar("w2q1");

body_start[8]=player.GetVar("w2a1");

body_start[9]=player.GetVar("w2q2");

body_start[10]=player.GetVar("w2a2");

body_start[11]=player.GetVar("w2q3");

body_start[12]=player.GetVar("w2a1");

body_start[13]=player.GetVar("line");

body_start[14]=player.GetVar("w3t");

body_start[15]=player.GetVar("w3st1");

body_start[16]=player.GetVar("w3q1");

body_start[17]=player.GetVar("w3a1");

body_start[18]=player.GetVar("line");

body_start[19]=player.GetVar("w3t");

body_start[20]=player.GetVar("w3st2");

body_start[21]=player.GetVar("w3q2");

body_start[22]=player.GetVar("w3a2");

body_start[23]=player.GetVar("line");

body_text = body_start[0] + "%0D%0A%0D%0A" + body_start[1] + "%0D%0A%0D%0A" + body_start[2] + "%0D%0A%0D%0A" + body_start[3] + "%0D%0A%0D%0A" + body_start[4] + "%0D%0A%0D%0A" + body_start[5] + "%0D%0A%0D%0A" + body_start[6] + "%0D%0A%0D%0A" + body_start[7] + "%0D%0A%0D%0A" + body_start[8] + "%0D%0A%0D%0A" + body_start[9] + body_start[10] + "%0D%0A%0D%0A" + body_start[11] + "%0D%0A%0D%0A" + body_start[12] + "%0D%0A%0D%0A" + body_start[13] + "%0D%0A%0D%0A" + body_start[14] + "%0D%0A%0D%0A" + body_start[15] + "%0D%0A%0D%0A" + body_start[16] + "%0D%0A%0D%0A" + body_start[17] + "%0D%0A%0D%0A" + body_start[18] + "%0D%0A%0D%0A" + body_start[19] + "%0D%0A%0D%0A" + body_start[20] + body_start[21] + "%0D%0A%0D%0A" + body_start[22] + "%0D%0A%0D%0A" + body_start[23];

var mailto_link='mailto:'+email+'?subject='+subject+'&body='+body_text;

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

When email is populated it only shows variables until body_start[17]=player.GetVar("w3a1"); and the rest do not show, is there a limit to how many variables i can call in my script please help

Be the first to reply