How to place a DIV over jw player when certain condition is met?
- by Derek
JW player can either playback video in flash or html5. I use a countdown timer in my app between certain videos. Right now the countdown timer is being displayed in a div beneath the jw player. I need to get that timer displayed in a div that covers the entire jw player interface.
I'm stuck and could use some help.
Here is some of the javascript code:
jwplayer("container").setup({
'file': 'devplaylist.xml',
'flashplayer': 'js/player.swf',
'plugins': {
'./countdown.js': {}
},
'repeat': 'list',
'autostart': true,
'height': 390,
'width': 720,
events: {
onPlaylist: function(event){
...
...
}
onPlaylistItem: function(event){
...
...
var minutes = (Math.floor(time/60 ));
var seconds = time % 60;
if (seconds < 10) seconds = "0" + seconds;
var text = minutes + ":" + seconds;
document.getElementById('resttimer').innerHTML = text;
//I need to have a DIV display the value of text (the countdown time)
//directly over the jw player
time--;
}, 1000);
...
...}
Any help is appreciated,
DK