var dftAlbumArt='http://cdnrf.securenetsystems.net/file_radio/stations_large/KBHR/v5/album-art-default.png'; var xmlpath='https://streamdb4web.securenetsystems.net/player_status_update/KBHR.xml'; var livepath='https://streamdb4web.securenetsystems.net/cirrusencore/KBHR'; var d = new Date(); var localServerTSoffset = d.getTime()+d.getTimezoneOffset()*60000 - Date.parse("10 Sep 2024 16:16:51"); //var stationSlogan="The Bear is Everywhere"; //load params var scripts = document.getElementsByTagName('script'); var index = scripts.length - 1; var myScript = scripts[index]; var queryString = myScript.src.replace(/^[^\?]+\??/,''); //console.log(queryString); var params = ssilive_parseQuery( queryString ); var rc=params['b']; var b_id=rc.replace('.',''); document.write('
'); //load jquery if is not included if(window.addEventListener){ window.addEventListener('load', ssiLiveButton_loadJq(b_id)) }else{ window.attachEvent('onload', ssiLiveButton_loadJq(b_id)) } function ssiLiveButton_loadJq(b_id){ //load jquery if is not present if (typeof(jQuery) == 'undefined') { var script = document.createElement('script'); script.type = "text/javascript"; script.onload = function(){ssiLiveButton_makeWidget(b_id);setTimeout("ssi_pulsateButton()",1000); } script.src = "https://ajax.googleapis.com/ajax/libs/jquery/1.11.0/jquery.min.js"; document.getElementsByTagName('head')[0].appendChild(script); }else{ ssiLiveButton_makeWidget(b_id); setTimeout("ssi_pulsateButton()",1000); } var cssfile = document.createElement('link'); cssfile.rel = "stylesheet"; cssfile.type = "text/css"; cssfile.href = "//radio.securenetsystems.net/cirrusencore/livebutton/livebutton.css"; document.getElementsByTagName('head')[0].appendChild(cssfile); }; function ssi_pulsateButton(){ //jQuery('.ssiLiveButton_playButtonClone').animate({opacity:0.3},{ duration: 800, queue: false, complete:function(){ssi_pulsateButtonBack() }}); //jQuery('.ssiLiveButton_playButtonClone').animate({borderLeftWidth:64,borderTopWidth:32,borderBottomWidth:32,bottom:'0px',right:'0px',opacity:0},{ duration: 1500, queue: false, complete:function(){ssi_pulsateButtonBack() }}); //jQuery('.ssiLiveButton_playButtonClone2').animate({borderLeftWidth:58,borderTopWidth:29,borderBottomWidth:29,bottom:'3px',right:'3px',opacity:1},{ duration: 1500, queue: false, complete:function(){ }}); } function ssi_pulsateButtonBack(){ //jQuery('.ssiLiveButton_playButtonClone').animate({opacity:0},{ duration: 200, queue: false, complete:function(){setTimeout("ssi_pulsateButton()",1000); }}); jQuery('.ssiLiveButton_playButtonClone').animate({borderLeftWidth:40,borderTopWidth:20,borderBottomWidth:20,bottom:'12px',right:'15px',opacity:0},{ duration: 200, queue: false, complete:function(){jQuery('.ssiLiveButton_playButtonClone').css('opacity',1);setTimeout("ssi_pulsateButton()",1500); }}); jQuery('.ssiLiveButton_playButtonClone2').animate({borderLeftWidth:40,borderTopWidth:20,borderBottomWidth:20,bottom:'12px',right:'15px',opacity:1},{ duration: 200, queue: false, complete:function(){ }}); } //get station settings and podcasts list function ssiLiveButton_makeWidget(b_id){ if (typeof(jQuery) == 'undefined') { setTimeout(function(){ssiLiveButton_makeWidget(b_id);},200); return false; } var xmlpath=jQuery("#b_"+b_id).data('xmlpath'); var localServerTSoffset=jQuery("#b_"+b_id).data('localservertsoffset'); jQuery.ajax({url: xmlpath+"?randStr=" + Math.random(), type: "GET", dataType: "xml", success: function(xml){ var nextsongReqTime=5000; if(jQuery(xml).find("programType").text() && jQuery(xml).find("title").text()){ if(jQuery(xml).find("title").text()==jQuery("#b_"+b_id).find('.ssiLiveButton_Title').text() && jQuery(xml).find("programStartTS").text()==jQuery("#b_"+b_id).find('.ssiLiveButton_text').data('programstartts')){ nextsongReqTime=2000; }else{ //console.log('set current play'); jQuery("#b_"+b_id).find('.ssiLiveButton_Title').html('