Name is required.
Email address is required.
Invalid email address
Answer is required.
Exceeding max length of 5KB

JW6 Captions - Language change with link


Hello!

We are still using JW6. I was wondering if it was possible to have a hyperlink on the page that changes the VTT file loaded in the player. Currently we have a player setup with multiple languages, but I'd like to make a link for the user to click to select their language. I am afraid they won't find the navigation bar with the captions selectable.

Also, is it possible to add a query string to a link and have it tell JWPlayer which language to load as the default?

Thank you!

1 Community Answers

Todd

JW Player Support Agent  
0 rated :

Yes, you can create an HTML button or link to call jwplayer().setCurrentCaptions(index)

Please see https://developer.jwplayer.com/jw-player/docs/developer-guide/api/javascript_api_reference/#captions for more details.

You could also potentially pass a URL parameter, parse it, and then make the same setCurrentCaptions() call on your page.

This question has received the maximum number of answers.