Forum Discussion
Here's an easy way to create a fullscreen button in Storyline
Hey all,
Just thought I'd pass along this tip for anyone that wants their users to view their courses in fullscreen.
Here's the example: https://360.articulate.com/review/content/47627759-c0a4-4921-a49a-785772d2f07a/review
To add it yourself, just add this "Execute Javascript" Code to any object and you're good to go.
var elem = document.documentElement;
function openFullscreen() {
if (elem.requestFullscreen) {
elem.requestFullscreen();
} else if (elem.webkitRequestFullscreen) { /* Safari */
elem.webkitRequestFullscreen();
} else if (elem.msRequestFullscreen) { /* IE11 */
elem.msRequestFullscreen();
}
}
function closeFullscreen() {
if (document.exitFullscreen) {
document.exitFullscreen();
} else if (document.webkitExitFullscreen) { /* Safari */
document.webkitExitFullscreen();
} else if (document.msExitFullscreen) { /* IE11 */
document.msExitFullscreen();
}
}
if(document.fullscreenElement == null){
openFullscreen();
}else{
closeFullscreen();
};
Cheers,
Andrew
Related Content
- 8 months ago
- 9 months ago
- 8 months ago
- 5 months ago