Forum Discussion
WebObject and Storyline Variable
I'm not sure how this will behave but you may have some luck hijacking the same function the Storyline player uses to show a web object. Execute this within a JavaScript trigger and you should be able to control the loaded URL. Here's an example:
OpenWebObject(1,"../../yourcontent.html",0,0,720,540,245,52);
Here's the function from story.js. This describes the parameters:
function OpenWebObject(strId, strUrl, nXPos, nYPos, nWidth, nHeight, nSlideXOffset, nSlideYOffset)
The values above provide an offset for a sidebar display at the default width and height. You may need to play with these values to get it to work.
You'll have problems with Web Objects in some browsers if your object target is cross browser. In your example above, you'd be able to employ storyline variables in your web object call something like this:
var player=GetPlayer();
var VariableSL1=player.GetVar("SLVariable1");
var VariableSL2=player.GetVar("SLVariable2");
var customURL="http://mywebobject.com/mysite.php?info1="+VariableSL1+"&info2="+VariableSL2;
OpenWebObject(1,customURL,0,0,720,540,245,52);