aFarkas/jMediaelement — Issue #13: jmeControl and Apache
Author: kudrom
Created: 2011-12-03 20:10:13+00:00
State: open

Hi,
i've embedded JME in a website. JME works if i use the file protocol but when i visit the web with apache it still play the video (it isn't the MIME type or the .htaccess) but the time slider, the volume slider, the user activity, the fullwindow or the media state stop working. The html is more or less the same as the official demos, i think the problem is with the jmeControl function because nothing below it is executed but the syntax is ok and it should work. It also doesen't work with jmeEmbed. Here is the javascript code:
```javascript
$(document).ready(function(){
$('html').addClass('js-on');
$(function (){
$('div.media-player')
.jmeControl({
addThemeRoller: false,
volumeSlider: {
range: 'min',
mutestate: true
},
timeSlider: {
range: 'min'
},
fullscreen: {
tryFullScreen: !!$.browser.mozilla
}
});
$('div.media-player').bind('useractive', function(){
$('div.media-controls', this).stop().animate({opacity: 1});
});
$('div.media-player').bind('userinactive', function(){
$('div.media-controls', this).stop().animate({opacity: 0});
});
$('div.media-controls', this).find('div.media-controls');
$('div.media-controls', this).css('opacity', 0);
$('video').bind('click',function(){
if (pausa==true){
$('video').togglePlay();
}
});
});
$(document).bind('play',function(){
$('.media-state').toggle();
pausa=true;
});
$(document).bind('pause',function(){
$('.media-state').toggle();
});
```