if(typeof sdb_settings_video_article_id === 'undefined') {
var sdb_settings_video_article_id = -1;
}
if(typeof sdb_settings_video_article_playlist === 'undefined') {
var sdb_settings_video_article_playlist = 0;
}
if(typeof sdb_settings_video_autostart === 'undefined') {
var sdb_settings_video_autostart = 'false';
}
var arrScripts = document.getElementsByTagName('script');
var jwplayersrc = false;
for(var i = 0; i < arrScripts.length-1; i++) {
if('http://jwpsrv.com/library/0v_1RNOaEeK3LBIxOQulpA.js' === arrScripts[i].src) {
jwplayersrc = true;
}
if("http://video.humo.be/v3/playyt-4rUMbmIbeZk.js" === arrScripts[i].src) {
arrScripts[i].id = 'script_1ed6ea6afe8890a63f0af0fcf7a2d641';
var strScriptTag_1ed6ea6afe8890a63f0af0fcf7a2d641 = arrScripts[i].id;
}
}
if(typeof strScriptTag_1ed6ea6afe8890a63f0af0fcf7a2d641 == 'undefined') {
// Add id to last script so the div can be added after this script
arrScripts[arrScripts.length - 1].id = 'script_1ed6ea6afe8890a63f0af0fcf7a2d641';
var strScriptTag_1ed6ea6afe8890a63f0af0fcf7a2d641 = arrScripts[arrScripts.length - 1].id;
}
if(!jwplayersrc) {
var jsfileref = document.createElement('script');
jsfileref.setAttribute("type", "text/javascript");
jsfileref.setAttribute("src", 'http://jwpsrv.com/library/0v_1RNOaEeK3LBIxOQulpA.js');
if(typeof jsfileref != "undefined") {
document.getElementsByTagName("head")[0].appendChild(jsfileref);
}
}
var wrapperdiv = document.createElement('div');
wrapperdiv.id = 'wrapperdiv_1ed6ea6afe8890a63f0af0fcf7a2d641';
wrapperdiv.setAttribute("style", "position: relative; background: #000;");
wrapperdiv.innerHTML = '
';
if(document.getElementById('script_1ed6ea6afe8890a63f0af0fcf7a2d641').parentNode.localName != 'head') {
document.getElementById('script_1ed6ea6afe8890a63f0af0fcf7a2d641').parentNode.insertBefore(wrapperdiv, document.getElementById('script_1ed6ea6afe8890a63f0af0fcf7a2d641').nextSibling);
}function sdb_video_1ed6ea6afe8890a63f0af0fcf7a2d641() {
var playerInstance;
if(sdb_settings_video_article_id == -1) {
playerInstance = jwplayer("videodiv_1ed6ea6afe8890a63f0af0fcf7a2d641").setup({
file: 'http://www.youtube.com/watch?v=4rUMbmIbeZk'
, image: ''
, height: '100%'
, width: '100%'
, autostart: sdb_settings_video_autostart
, skin: 'http://video.humo.be/v3/humoskin.xml'
, primary: jwplayer.utils.isChrome() ? "flash" : "html5"
, ga: {idstring: ''}
});
} else {
playerInstance = jwplayer("videodiv_1ed6ea6afe8890a63f0af0fcf7a2d641").setup({
file: 'http://www.youtube.com/watch?v=4rUMbmIbeZk'
, image: ''
, height: '100%'
, width: '100%'
, autostart: sdb_settings_video_autostart
, skin: 'http://video.humo.be/v3/humoskin.xml'
, primary: jwplayer.utils.isChrome() ? "flash" : "html5"
, ga: {idstring: ''}
, related: { file: 'http://www.humo.be/ajax/videorelated/' + sdb_settings_video_article_id.toString(), onclick: 'link', heading: 'Bekijk ook', dimensions: '220x140' }
});
// console.log('Debug: Related Xml: http://www.humo.be/ajax/videorelated/' + sdb_settings_video_article_id.toString());
}
playerInstance.onPlay(function() {
if(sdb_settings_video_article_id != -1 && typeof setVideoWatched == 'function') {
setVideoWatched(sdb_settings_video_article_id);
}
});
playerInstance.onComplete(function() {
if(sdb_settings_video_article_id != -1 && sdb_settings_video_article_playlist == 1 && typeof loadPlaylistVideo == 'function' && typeof getNextPlaylistVideoIndex == 'function') {
var next_index = getNextPlaylistVideoIndex();
if(next_index) {
loadPlaylistVideo(sdb_settings_video_article_id.toString(), next_index.toString());
}
}
});
}
var sdb_checkLoadsdb_video_1ed6ea6afe8890a63f0af0fcf7a2d641 = function() {
if(typeof jwplayer !== 'function') {
setTimeout(sdb_checkLoadsdb_video_1ed6ea6afe8890a63f0af0fcf7a2d641, 100);
} else {
sdb_video_1ed6ea6afe8890a63f0af0fcf7a2d641();
}
};
sdb_checkLoadsdb_video_1ed6ea6afe8890a63f0af0fcf7a2d641();