Code to Disappear a Video Box

Question:
Hello! I’m working in Wix Studio and I have a Video Box that I’m trying to have fade away once it finishes playing after 20 seconds. Is there any code that can help make that happen? Thanks :slight_smile:

Product:
Wix Studio Editor

Hi, tyjordan2016 !!

A simple example might look something like this,

$w("#yourVideoBox").onEnded(() => {
    setTimeout(() => {
        $w("#yourVideoBox").hide("fade");
    }, 20000); // 20000 milliseconds = 20 seconds
});

Good luck !! :wink:

1 Like