Reputation: 13046
I used jPlayer before and the html markup of the player is in the page source directly, I'm trying mediaelement.js now, and I coded my audio player (html/css) but I don't know how to use it the right way with mediaelement.js.
so mediaelement.js adds the html markup to all the audio and video tags:
$('audio,video').mediaelementplayer(); // using the jQuery version
so the only way to get the player's markup is to inspect the element with chrome developer tools and copy it.
but is this the right way to make a skin for mediaelement ? I think there must be a better way that I'm not aware of.
I searched but couldn't find any guides for this, I found this here on stackoverflow:
Rolling custom control buttons
And thanks in advance.
Upvotes: 1
Views: 4335
Reputation: 94
Actually using inspect the element with chrome developer tools is the easy way to give style. At worst you can override it.
On the other hand I have to suggest you use mode:shim for browser supports
$('audio,video').mediaelementplayer({
mode:'shim',
startVolume: 0.8,
loop: false,
features: ['playpause','duration','volume'],
success: function(player, node) {
//success codes here
}
});
Upvotes: 2