Help! Storyline 2: iFrame Content Automatically Grabs Focus in Web Browser
Jan 06, 2015
Hello. I embed Storyline objects in HTML files using an iframe. In the past, I stopped the page from jumping down to the Storyline (1) file by commenting out the following in the story.js file (as described here: http://www.articulate.com/support/storyline-2/iframe-content-automatically-grabs-focus-in-web-browser-sl2):
case "BW_RestoreFocus":
var oPlayer = GetPlayer();
try
{
oPlayer.tabIndex = 0;
oPlayer.focus();
}
catch (e)
{
}
break;
However, this same snippet of code is not included in the Storyline 2 output. When commenting out the following similar code in the Storyline 2 output, I have no luck in IE:
case "BW_RestoreFocus":
SetPlayerFocus();
break;
Any suggestions?
Thanks!!
5 Replies
Hi Lindsay,
If you use an iFrame to embed a published Articulate Storyline course into a web page, you may find that the web page automatically scrolls down to the iFrame when it's viewed in Internet Explorer or Firefox.
This results from a browser conflict with code that allows keyboard commands to function as soon as a page loads. Use any of the following options to avoid this behavior.
Thanks Ashley, but I referenced that same link in my original post. The story.js file in the Storyline 2 output doesn't include the code mentioned in the article. I am looking for a way to modify the Storyline 2 output in a similar way.
Hi Lindsay,
Sorry - I missed the link in your first post. I'm unable to assist with making modifications to the published output - but hope that the community will chime in to assist you if they have thoughts to share.
Hi Ashley,
Has anyone at Articulate managed to get a fix for this issue yet please?
Hi Stu,
Thanks for reaching out here - I hadn't seen any other fixes other than the one mentioned in that article above, and JS code is not something I can assist with - but I see you also posted here and may have created a fix. Just wanted to link to the two threads for anyone who may stumble upon this one!
This discussion is closed. You can start a new discussion or contact Articulate Support.