function launchPlayer(playlist_url) { var jukebox_url = "http://www.austin360.com/music/content/music/soundcheck/player/player.html"; if (playlist_url) { jukebox_url += "?playlist_url="+escape(playlist_url); } newWindow(jukebox_url, "jukebox", 775, 600); } function newWindow(mypage, myname, w, h) { var winl = (screen.width-w)/2-8; var wint = ((screen.height-h)/2)-50; var settings = 'height='+h+',width='+w+',top='+wint+',left='+winl+',scrollbars=no,toolbar=no,location=no,status=no,menubar=no,resizable=no'; var win = window.open(mypage, myname, settings); if (parseInt(navigator.appVersion) >= 4) { win.window.focus(); } } function getArgs() { var args = new Object(); var query = this.location.search.substring(1); //query = unescape(query); query = query.replace("?",""); var pairs = query.split("&"); // Break at comma. for(var i = 0; i < pairs.length; i++) { var pos = pairs[i].indexOf('='); // Look for "name=value". if (pos == -1) continue; // If not found, skip. var argname = pairs[i].substring(0, pos); // Extract the name. var value = pairs[i].substring(pos+1); // Extract the value. args[argname] = unescape(value); // Store as a property. } return args; // Return the object. } function getVar(variable) { var args = getArgs(); var hold; hold = args[variable]; // Get arguments. return hold; } function setupFlashPlayer() { var server = getVar("server"); var playlist_url = escape(getVar("playlist_url")); if (!server || server == "" || server == "undefined") { server = "http://jukebox.statesman.com/"; } if (!playlist_url || playlist_url == "" || playlist_url == "undefined") { playlist_url = "getAllTracks/"; } flashContent("jukebox", "http://alt.coxnewsweb.com/austin360/jukebox/music_jukebox.swf", "100%", "100%", "transparent", "#333333", "high", "middle", 8, "server="+server+"&playlist_url="+playlist_url); } function setupMiniPlayer(playlist, server) { if (!server || server == "" || server == "undefined") { server = "http://jukebox.statesman.com/"; } if (!playlist || playlist == "" || playlist == "undefined") { playlist = "getPlaylistByName/New In Soundcheck/"; } flashContent("jukebox", "http://alt.coxnewsweb.com/austin360/jukebox/jukebox_mini.swf", "285", "35", "transparent", "#333333", "high", "middle", 8, "server="+server+"&playlist_url="+playlist); } function flashContent(name, src, w, h, wmode, bgcolor, quality, align, version, vars) { var embed_string = ''; obj_string += ''; obj_string += ''; obj_string += ''; obj_string += ''; obj_string += ''; if (vars) { obj_string += ''; } obj_string += embed_string; obj_string += ''; document.write(obj_string); } function getAd() { var iframe = document.getElementById("dogear").getElementsByTagName("iframe")[0]; iframe.src = "player_top_dogear.html"; //iframe.src; //document.getElementById("dogear").getElementsByTagName("iframe")[0].src = "http://ad.doubleclick.net/adj/aus360.cni/home;ap=hp;pg=home;sub=index;fromsite=austin360;swrd=;ura=;urg=;urz=;urm=;urn=;ptile=7;sz=180x60;ord=1785577500?"; //makeRequest("jukebox.php"); //makeRequest("http://ad.doubleclick.net/adj/aus360.cni/home;ap=hp;pg=home;sub=index;fromsite=austin360;swrd=;ura=;urg=;urz=;urm=;urn=;ptile=7;sz=180x60;ord=1785577500?"); } function gotoLink(url) { try { if (window.opener && !window.opener.closed) { window.opener.focus(); window.opener.location = url; } else { window.open(url); } } catch(err) { window.open(url); } } function makeRequest(url) { var http_request = false; if (window.XMLHttpRequest) { // Mozilla, Safari, ... http_request = new XMLHttpRequest(); if (http_request.overrideMimeType) { http_request.overrideMimeType('text/plain');//('text/xml'); // See note below about this line } } else if (window.ActiveXObject) { // IE try { http_request = new ActiveXObject("Msxml2.XMLHTTP"); } catch(e) { try { http_request = new ActiveXObject("Microsoft.XMLHTTP"); } catch(e) { return false; // could not create XMLHttpRequest Object alert('Giving up :( Cannot create an XMLHTTP instance'); } } } http_request.onreadystatechange = function() { alertContents(http_request); }; http_request.open('GET', url, true); http_request.send(null); } function alertContents(http_request) { if (http_request.readyState == 4) { if (http_request.status == 200) { alert(http_request.responseText); //document.getElementById("dogear").innerHTML = http_request.responseText; } else { alert('There was a problem with the request.'); } } }