Multiple languages in TOC

Jun 22, 2020

I am going to have a course that is in 3 (or more) languages. Each language will be a Scene, and the learner will select their language on the first slide.

Is there a way in which I can show them only their language slides in the TOC and not for all the other languages?

4 Replies
Sam Hill

Hi Chantal, I don't think this is possible via Storyline configuration. There is no means to show TOC item based on a language selection.

Others might have better suggestions, but you could hide certain menu options using JavaScript based on the language selection.

I provided a solution for another user who wanted to hide certain menu options based on the user type, but could be adapted to a language selection.

You would have a Storyline variable called "lang" which would be set to the language value based on the users choice. That is then mapped to a menu item in the TOC to ensure it is the only one shown.

This isn't fully tested, but should be close to what you will need.

var player = GetPlayer();
var lang = player.GetVar('lang'); // get language from Storyline
var menu = document.querySelector('ul[aria-label="Menu"]'); // main menu
var mapping = {
'en' : 0,
'fr' : 1,
'ch' : 2
}; // languages mapped to the menu items to hide = "none"; // hide all other lang
menu.children[mapping[lang]].style.display = "list-item"; // show this lang
Ned Whiteley

Hi Chantal,

I agree with Sam that there is no way in the Storyline configuration options to selectively show the TOC based on language.

Another alternative is to not show the TOC at all in your Player, but to instead use a lightbox slide to enable the TOC to be viewed by the user whenever they need to see it.

In the attached example, I have set up a basic outline of a three-language course where each separate language has its own Scene and each scene contains its own version of the interactive TOC as a lightbox slide in the appropriate language. In order to see the TOC the user simply selects the button in the top right corner or the slide (you would probably want to format this to be more in keeping with the rest of your slide branding or even use a menu icon - I have simply shown a basic button for demonstration purposes).

The user can then navigate from the TOC by clicking on the appropriate item in the contents list.