var jsArray = { swfobject: 'http://www.focus-brandstore.be/swfobject.js', // Home homepage: 'http://www.focus-brandstore.be/homepage.js', // Home jquery_wipetouch: 'http://www.focus-brandstore.be/jquery.wipetouch.js', // Home stay_standalone: 'http://www.focus-brandstore.be/stay_standalone.js', // Mobile touch_scroll: 'http://www.focus-brandstore.be/touch-scroll.mod.js' // Mobile } var jsCDN = { jquery_ui: 'https://ajax.googleapis.com/ajax/libs/jqueryui/1.8.13/jquery-ui.min.js' // Home } /* Home -------------------------------*/ if ( $('.homepage').length ) { $.getScript(jsArray.jquery_wipetouch); $.getScript(jsCDN.jquery_ui, function(){ $.getScript(jsArray.homepage); }); $.getScript(jsArray.mediaelement, function(data, textStatus) { $.getScript(jsArray.videocomponent, function(){ videoPlayer.init(true); }); }); } /* Mobile -------------------------------*/ if ( mobile() ) { $.getScript(jsArray.stay_standalone); $.getScript(jsArray.touch_scroll,function(){ if (!!('ontouchstart' in window) && $('.grid-horizontal').length == 0 && $('#video-channel').length == 0 ) { $('div#main-content').touchScroll(); } }); $.getScript(jsArray.iscroll); }