I got help on a danish forum a guy made an example i could modify for my own project it worked for me the solution:
Html5 Video. After 20 secs of pause reset player
-
14-04-2022 - |
题
So im working on a school project for a museum, we are making an info screen with a video to play for the visitors, ill like to make a function so that if one visitor is pausing the video and leave it will reset after 20 sec or so. So the next visitor dont have to reset the video by him self.
Any easy way to do that?
I just use the standard html5 video player and controls.
解决方案 2
其他提示
http://blog.teamtreehouse.com/building-custom-controls-for-html5-videos it might help probably you need to write your required code within
if (video.paused == true)
{
//find out code to find whether its been paused for 20 second.....may be use some timer control to get this
if(20secPaused)
{
video.currentTime = time;
}
hope it helps :)
不隶属于 StackOverflow