4 Replies
Luke Mosse

I've actually found this on another thread.

You can! The code is as follows:

function getQueryVal(variable) {
var query = window.location.search.substring(1);
var vars = query.split('&');
for (var i = 0; i < vars.length;i++){
var pair = vars[i].split('=');
if (decodeURIComponent(pair[0]) == variable) {
return decodeURIComponent(pair[1]);
var player=GetPlayer();
//storyline variables userName and userID must exist for this to work
player.SetVar("userName", getQueryVal("userName"));

It uses "?" as a separator, and you append variables to the URL query. If
you need any help with it let me know. I had to repair the "for" loop
because on the original it had erased some of it on posting, so hopefully
this will remain in tact.