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

Auto stop


Hello!
I have a question: I Broadcasts RTMP stream from the camera. How do I do that during video playback was stopped after 20 minutes. If a person needs to look again, he has to press "Play". This is necessary to reduce the camera chtby load, if a person left on playback and left.

2 Community Answers

Todd

JW Player Support Agent  
0 rated :

There are a few ways to do this, but perhaps the easiest is to start a Javascript timer when playback first starts. Then you can set your Javascript timer to call jwplayer().stop().

The code would look something like this:

jwplayer().on('firstFrame',function(){
	setTimeout(function(){
		console.log("Timer's up!");
		jwplayer().stop(true);
	},1200000); //this number is in milliseconds, so 1 second = 1000
});

g...

User  
0 rated :

Thank you very much!

This question has received the maximum number of answers.