<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<title>clappr</title>
<script src="http://cdn.clappr.io/latest/clappr.min.js"></script>
</head>
<body>
<div id="player"></div>
<script>
var playlist = [
'http://clappr.io/highline.mp4',
'http://vjs.zencdn.net/v/oceans.mp4',
'http://d11.cdnvideo.ru/videojs/files/hypnofrog.mp4',
'http://d11.cdnvideo.ru/videojs/files/m1080.mp4'
];
var player = new Clappr.Player({
source: playlist.shift(),
parentId: "#player",
autoPlay: true,
hideMediaControl: false,
});
// fired when player ends the video
player.on(Clappr.Events.PLAYER_ENDED, function () {
if (playlist.length > 0) {
player.load(playlist.shift());
}
});
</script>
</body>
</html>
player.getPlugin('plugin_name').$el.remove();