auto recconect when you lost internet connection
i am trying to enable auto reconnect when someone loss internect conection the player would be auto reconnect automatically after they reestablish internet connection.
i am using this embed code:
<!DOCTYPE html>
<html>
<head>
<script src="http://jwpsrv.com/library/pgTaLK3jEeOqIiIACmOLpg.js"></script>
</head>
<body>
<div id='playerQkbZizdfJlia'></div>
<script type='text/javascript'>
jwplayer('playerQkbZizdfJlia').setup({
file: 'rtmp://208.100.14.24/vod/mp4:sample.mp4',
image: 'http://www.longtailvideo.com/content/images/jw-player/lWMJeVvV-876.jpg',
title: 'test',
width: '640',
height: '360',
autostart: 'true',
primary: 'flash'
});
jwplayer().onError(function(){
jwplayer().load({file:"http://content.jwplatform.com/videos/7RtXk3vl-52qL9xLP.mp4",image:"http://content.jwplatform.com/thumbs/7RtXk3vl-480.jpg"});
jwplayer().play();
});
jwplayer().onComplete(function(){
window.location = window.location.href;
});
jwplayer().onBuffer(function(){
theTimeout = setTimeout(function(){
jwplayer().load({file:"http://content.jwplatform.com/videos/7RtXk3vl-52qL9xLP.mp4",image:"http://content.jwplatform.com/thumbs/7RtXk3vl-480.jpg"});
jwplayer().play();
},5000);
});
jwplayer().onPlay(function(){
clearTimeout(theTimeout);
});
</script>
</body>
</html>
----------------------------------------------------
here is a video sample for other website that use auto reconnect, i would like to use something similar to enable in my jwplayer. also i upload a sample video using the jwplayer embed code to auto reconnect, but it looks that is not working properly. you can see in the video.
http://208.100.14.24/sampletest/livestream.wmv
208.100.14.24/sampletest/jwplayer.wmv
also it would be great if you enable this autoreconnect option in jwplayer -->control panel , publish-> your website