Sending cookies from Storyline to a new window

Jul 09, 2019

Hi everyone,

I have a Stroyline module that was developed by someone else and uses a javascript code to send content to a new window using cookies. The code uses the Cookies.set function which seems to work fine in previous Storyline versions but is no longer working when currently publishing the file from my updated Storyline 360.

Here's what the code looks like:  

var player = GetPlayer();
var reflection1 = player.GetVar("reflection1");

Cookies.set("Cookie1",reflection1, 'path: "/"');

From what I've been able to find on js this syntax is correct, and also as mentioned worked fine in previously published versions. Using alerts I can see that currently the Cookies.set line doesn't run (meaning an alert after line 2 works, an alert after line 3 doesn't). 

I tried using the document.cookie function but it doesn't seem to work either. I believe because I'm attempting to send the cookies to a new window (SL trigger to open file, the file is .html and has code to read the cookies).

Has anyone else come across this issue? Any leads will be helpful! 

Be the first to reply

This discussion is closed. You can start a new discussion or contact Articulate Support.