I am using jwplayer to play videos on my site. I want to implement this scenario :
- A small thumb nail image represent the video.
- when a user click on the thumb image the jwplayer div shows and starts to play and the thumb image will hide .
- An external close button will allow to close the video. Then the thumb image will show again.
I am trying to accomplish it by using js. The following is used to play the video:
jwplayer('container').play();
and this is used to stop the jwplayer:
jwplayer('container').stop();
The functions are working in chrome . But in firefox when I try to play the video in second time the jwplayer is in BUFFERING state. Also revert back to the placeholder image.
also shows an error sometime in console
Error: Permission denied to access property 'toString'
This is a sample jsfiddle demo
Please help me to find a solution for this.
Thanks