"}'); var vid = document.getElementById('videojsCustomPlayer'); var sources = []; if(xn_r.hasOwnProperty('med')){ sources.push({type: 'video/mp4', src: xn_r.med, label: 'medium'}); } var player = videojs("videojsCustomPlayer", { "controls": true, "preload": "auto", "sources": sources, nativeControlsForTouch: false, "autoplay": false, "muted": false, "playbackRates": [1, 1.5, 2], "width": window.innerWidth, "height": window.innerHeight, }); } catch (e){ console.log(e); }