openWebObject JavaScript - Differences between SL1 and SL2?

Does anyone know what's changed between SL1 and SL2 with regards to using the openWebObject function via an Execute JavaScript trigger?

In SL1 this code:

var customURL="http://webmedia.unmc.edu/nursing/heroes/ilm/misc/webobject.html"; OpenWebObject(1,customURL,145,390,740,160,0,0);

works as expected.

However, in SL2, nothing appears to be happening.

The SL2 version linked above was built from scratch, but converting the SL1 .story file has the same result - no Web Object displayed.

 

3 Replies
Ashley Terwilliger-Pollard

Hi Stephen,

I don't know of any changes in the code from SL1 to SL2, and I did reach out to my colleagues to see if they knew of something specific - but Javascript code is not something I'm equipped to support. You may want to tag along into this thread, as it looks like Marco has some ideas about a similar situation. 

Marco Faust

Stephen,

If you add these two lines of code to what you have, I think you will see it (not verified):

var oWebObject1 = g_oWebObjects["1"];
oWebObject1.Div.style.zIndex = 900 ;

As with the other thread, the problem is that the OpenWebObject code is setting the zindec to -1 which places it behind the player.  It's actually there on your page, but you can't see it.