Created
June 27, 2016 20:18
-
-
Save mjgorman/5ca9f6bf843a2db5c21e1d41f5d39c6a to your computer and use it in GitHub Desktop.
siriusxm player source
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!DOCTYPE html> | |
<!--[if IE 8 ]> <html class="ie8" xmlns:ng="http://angularjs.org/"> <![endif]--> | |
<!--[if (gt IE 8)|!(IE)]><!--> <html xmlns:ng="http://angularjs.org/"> <!--<![endif]--> | |
<head> | |
<!--[if IE 8 ]> <meta http-equiv="X-UA-Compatible" content="IE=8"> <![endif]--> | |
<!--[if IE 9 ]> <meta http-equiv="X-UA-Compatible" content="IE=9"> <![endif]--> | |
<!--[if (gt IE 9) ]> <meta http-equiv="X-UA-Compatible" content="IE=edge"> <![endif]--> | |
<meta charset="utf-8"> | |
<meta name="viewport" | |
content="width=device-width, height=device-height, initial-scale=1.0"> | |
<title>SiriusXM</title> | |
<!--[if IE 8 ]> | |
<link rel="stylesheet" href="assets/css/ie8.css"> | |
<script src="scripts/compiled/vendor_legacy.js"></script> | |
<![endif]--> | |
<!--[if (gt IE 8)|!(IE)]> <!--> | |
<script type="text/javascript" src="/dtagent625_gbxj_3027.js" data-dtconfig="rid=RID_2418|rpid=1704664488|domain=siriusxm.com|tp=500,50,0|bandwidth=300_m|reportUrl=dynaTraceMonitor"></script><script src="scripts/compiled/vendor_modern.js"></script> | |
<!--<![endif]--> | |
<script src="vendor/swf-storage/swfstore.min.js" type="text/javascript"></script> | |
<!--[if IE 9 ]><link rel="stylesheet" href="assets/css/ie8.css"><![endif]--> | |
<!--[if (lt IE 10)]> <!--> | |
<!--<script src="vendor/utils/jquery.placeholder.js"></script>--> | |
<!--<![endif]--> | |
<script src="scripts/compiled/app.js?ver=2a93211f41e254c804c5fdd234163eefa4413703"></script> | |
<!-- Below is the code for maxymiser where the expectation is to load this script before other injected scripts --> | |
<!--[if (gt IE 8)|!(IE)]> <!--> | |
<script type="text/javascript" src="//service.maxymiser.net/cdn/siriusxm/js/mmcore.js"></script> | |
<!--<![endif]--> | |
<!--NOTE: 2.3.2--> | |
<link rel="stylesheet" | |
href="vendor/bootstrap/docs/assets/css/bootstrap.css"> | |
<link rel="stylesheet" | |
href="vendor/font-awesome/css/font-awesome.css"> | |
<link rel="stylesheet" | |
href="vendor/blueimp-gallery/css/blueimp-gallery.css"> | |
<link rel="stylesheet" | |
href="vendor/blueimp-gallery/css/blueimp-gallery-indicator.css"> | |
<!--NOTE: 3.0.0--> | |
<!--<link href="//netdna.bootstrapcdn.com/bootstrap/3.0.0/css/bootstrap.min.css" rel="stylesheet">--> | |
<!--<script src="//netdna.bootstrapcdn.com/bootstrap/3.0.0/js/bootstrap.min.js"></script>--> | |
<link rel="stylesheet" | |
type="text/css" | |
href="assets/k2-web-client-0.0.1.css?v=2a93211f41e254c804c5fdd234163eefa4413703"/> | |
<style> | |
html { | |
display: none | |
} | |
</style> | |
<script> | |
if (self === top) | |
{ | |
document.documentElement.style.display = 'block'; | |
} | |
else | |
{ | |
top.location = self.location; | |
} | |
</script> | |
<script type="text/javascript"> | |
function setBackgroungImage(webLoginURL) | |
{ | |
if(window.location.href.indexOf("local")>-1) | |
{ | |
webLoginURL = "http://player-k2uat2.mountain.siriusxm.com/images/Web-1280x1000.jpg"; | |
} | |
var obj = document.getElementById("loading"); | |
obj.style.backgroundImage = "url('assets/images/Web-1280x1000.jpg')"; | |
} | |
function getCookie(cookieName) | |
{ | |
var name = cookieName + "="; | |
var ca = document.cookie.split(';'); | |
for(var i = 0, len = ca.length; i < len; i++) | |
{ | |
var c = ca[i]; | |
c = c.replace(/\ /g, ""); | |
if(c.indexOf(name) !== -1) | |
{ | |
return c.substring(name.length, c.length); | |
} | |
} | |
return ""; | |
} | |
function removeURLParam(key) | |
{ | |
var params = window.location.href.split("?")[1]; | |
if(params) | |
{ | |
var paramArray = params.split("&"); | |
for(var i = 0; i < paramArray.length; i++) | |
{ | |
var param = paramArray[i].split("="); | |
if(param[0] === key) | |
{ | |
return true; | |
} | |
} | |
} | |
return false; | |
} | |
function getURLParam(key) | |
{ | |
var params = window.location.href.split("?")[1]; | |
if(params) | |
{ | |
var paramArray = params.split("&"); | |
for(var i = 0; i < paramArray.length; i++) | |
{ | |
var param = paramArray[i].split("="); | |
if(param[0] === key) | |
{ | |
return true; | |
} | |
} | |
} | |
return false; | |
} | |
function bindSplashLogo() | |
{ | |
//debugger; | |
var isLogout = getURLParam("logout"); | |
if(isLogout === true) | |
{ | |
document.getElementById("splash-logo").className = "logging-out-logo"; | |
window.location.href = window.location.href.replace("logout=true",""); | |
} | |
else | |
{ | |
document.getElementById("splash-logo").className = "splash-logo"; | |
} | |
} | |
function bindWebLoginImg() | |
{ | |
bindSplashLogo(); | |
var url = getCookie("webLogin"); | |
setBackgroungImage(url); | |
var url = window.location.href.split("#")[0]; | |
if(url.split("?").length>1) | |
{ | |
var urlArray = url.split("?"); | |
url = urlArray.shift(); | |
} | |
url+= "proxy.html"; | |
url = url.split("https").join("").split("http").join(""); | |
url = "https"+url; | |
document.getElementById('proxy').src = url+"?ver=2a93211f41e254c804c5fdd234163eefa4413703"; | |
} | |
function checkLSO() | |
{ | |
try{ | |
try | |
{ | |
if(window.localStorage) | |
{ | |
if(window.localStorage.getItem('k2.clientDeviceId') && window.localStorage.getItem('k2.clientDeviceId')!=="null") | |
{ | |
window.k2ClientDeviceId = window.localStorage.getItem('k2.clientDeviceId'); | |
} | |
if(window.localStorage.getItem("k2.language")) | |
{ | |
window.languagePreference = window.localStorage.getItem("k2.language"); | |
} | |
} | |
} | |
catch(err) | |
{ | |
// fallback if localstorage is not available | |
if(getCookie("k2language")!="") | |
{ | |
window.languagePreference = getCookie("k2language"); | |
} | |
} | |
// wait until the page has finished loading before starting | |
window.mySwfStore = new SwfStore({ | |
context: "SiriusXM", | |
namespace: '112720111157', // the this must match all other instances that want to share cookies | |
swf_url: 'vendor/swf-storage/storage.swf', // to work cross-domain, use the same absolute url on both pages (meaning http://site.com/path/to/store.swf not just /path/to.store.swf. You may need to use // instead of https:// to work around flashplayer bugs.) | |
onready: function(){ | |
if(!window.k2ClientDeviceId) | |
{ | |
window.k2ClientDeviceId = window.mySwfStore.get('k2.clientDeviceId'); | |
window.lsoDone = true; | |
if(window.k2ClientDeviceId==="null") | |
{ | |
window.k2ClientDeviceId = null; | |
return; | |
} | |
try | |
{ | |
if(window.localStorage) | |
{ | |
window.localStorage.setItem('k2.clientDeviceId', window.k2ClientDeviceId); | |
} | |
} | |
catch(err) | |
{ | |
} | |
} | |
}, | |
onerror: function(err){ | |
// in case we had an error. (The most common cause is that the user disabled flash cookies.) | |
window.lsoDone = true; | |
} | |
}); | |
} | |
catch(err) | |
{ | |
window.lsoDone = true; | |
} | |
} | |
function onPlayhead(event) | |
{ | |
if(window.onPlayheadHandler) | |
{ | |
event.id = event.target.id; | |
event.playbackType = event.target.playbackType; | |
window.onPlayheadHandler(event); | |
} | |
} | |
</script> | |
<!--[if IE]> | |
<script type="text/javascript"> | |
function cleanupForIE() { | |
try { | |
//get using the id of your swf instance | |
var swf = document.getElementById('web-audio-player'); | |
if(swf) | |
{ | |
try{ | |
swf.parentNode.removeChild(swf); | |
} | |
catch(err) | |
{ | |
if(console && console.log) | |
{ | |
console.log(err); | |
} | |
} | |
swf.disconnect(); | |
} | |
} catch(e) { | |
if(console && console.log) | |
{ | |
console.log("Error on unload: " + e); | |
} | |
} | |
try | |
{ | |
swfobject.removeSWF("web-audio-player"); | |
} | |
catch(e) | |
{ | |
if(console && console.log) | |
{ | |
console.log(e); | |
} | |
} | |
} | |
window.attachEvent("onbeforeunload", cleanupForIE); | |
</script> | |
<![endif]--> | |
</head> | |
<body onload="bindWebLoginImg(); checkLSO();"> | |
<iframe id="proxy" style="width:0px;height:0px;border: none;float: left;"></iframe> | |
<div id="loading"> | |
<div id="splash-logo"></div> | |
<!-- <div id="logout-progress-image" class="logging-out-logo"></div> --> | |
</div> | |
<!-- | |
// *********************************************************************** | |
// AngularJS App | |
// *********************************************************************** | |
//--> | |
<div id="viewport" data-version="2a93211f41e254c804c5fdd234163eefa4413703" | |
ng:controller="appController" | |
ng-cloak=""> | |
<div id="content"> | |
<div id="wrapper" | |
ng:view> | |
</div> | |
</div> | |
</div> | |
<script src="vendor/utils/head.load.js" | |
type="text/javascript"></script> | |
<script src="src/sxm/bootstrap.js?v=2a93211f41e254c804c5fdd234163eefa4413703" | |
type="text/javascript"></script> | |
<div id="flash_div"> | |
</div> | |
</body> | |
</html> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment