Adding an in-course option to globally toggle closed captions on/off.
I know that you can set closed captions to be automatically on or off at the title level. But either option can be a distraction for those who want / don't want them on. Is there a way that we can add some sort of button at the beginning of the course that gives the user the option to have all closed captions turned either on or off?
VarTrivSelCap.set('en'); for Captions ON VarTrivSelCap.set('none'); for Captions OFF2
@jholland We're using Lectora Online, not sure if that makes a difference. But the JS you provided is calling on a variable that's not in the course. Is that a variable we're supposed to create? We need a little more guidance. Help!0
wheels Community Member, Administrator, Moderator, Rockstar Manager Posts: 700 eLearning ROCKSTAR Admin TeamIn Lectora Online the variable is different! It is called VarTriCCState so:
VarTriCCState.set('en'); for Captions ON VarTriCCState.set('none'); for Captions OFFYou should not try to create the variable.0
@wheels Thank you so much! That works like a charm.
Do you by any chance know if there's a way to get the VarTriCCState to be remembered by the browser/LMS?0
wheels Community Member, Administrator, Moderator, Rockstar Manager Posts: 700 eLearning ROCKSTAR Admin TeamWe will look into making this easier in the future.
To save the state you will need to set to a user variable. Add a user variable in the Variable Manager and set it to Retain variable value between sessions. Then you can set up some actions that do things conditionally based on your variable. For instance if your variable is named CCON :
On Page Show -> Show the Turn CC Off for the course button IF CCON is Empty
On Page Show -> Show the Turn CC On for the course button IF CCON is Empty
The Turn CC Buttons would also do a Modify Variable Action that set CCON to en or none.
Hope this helps.
- 35.9K All Categories
- 110 ✫ Announcements
- 33.2K Lectora®
- 31.1K Lectora Discussions
- 29K Lectora Desktop
- 2K Lectora Online
- 2K Lectora Feature Requests
- 71 Lectora User Groups
- 27 ELB Learning Content
- 27 ELB Learning Content Discussions
- 343 CenarioVR®
- 204 CenarioVR Discussions
- 139 CenarioVR Feature Requests
- 44 Rockstar Learning Platform®
- 41 Rockstar Learning Platform Discussions
- 108 CourseMill®
- 108 CourseMill Discussions
- 48 ReviewLink®
- 48 ReviewLink Discussions
- 7 The Training Arcade®
- 7 The Training Arcade Discussions
- 938 All Things eLearning
- 39 eLearning Development
- 546 Learning Management System (LMS) Integration
- 333 Web Accessibility
- 1.2K ♪ The Green Room
- 9 Additional Learning Products