// popup windows
function openWin(theURL, theName, theWidth, theHeight, theBars)
{
   var width=theWidth;
   var height=theHeight;
   var theName=theName;
   var bars=theBars;
   var winl = (screen.width - width) / 3;
   var wint = (screen.height - height) / 2;
   var theFeatures = "width=" + width + ",height=" + height +",top="+wint+",left="+winl+",scrollbars="+bars;
                                
   var theWin = window.open(theURL,theName,theFeatures);
         theWin.focus();
}

function openVid(url){
	openWin(url,'foxVideoPlayer','656','680');
}

function openMus(url){
	openWin(url,'foxMusicPlayer','653','310');
}

// query variable from url string
function getVar(variable) {
	var query = window.location.search.substring(1);
	var vars = query.split("&");
	for (var i=0;i<vars.length;i++) {
		var pair = vars[i].split("=");
		if (pair[0] == variable) {
			return pair[1];
		}
	}
	return "";
}





// Floating Nav stuff starts here ////////////////////

function showMenu() {
self.name = "sitemain"; // names current window as "main"

var windowprops = "toolbar=0,location=0,directories=0,status=0, " +
"menubar=0,scrollbars=0,resizable=0,left=25,top=25,width=200,height=300";

OpenWindow = window.open("menu.htm", "mymenu", windowprops);
}

function setVariables(){
if (navigator.appName == "Netscape") {
v=".top=";h=".left=";dS="document.";sD="";
y="window.pageYOffset";x="window.pageXOffset";iW="window.innerWidth";iH="window.innerHeight"

}

else {h=".pixelLeft=";v=".pixelTop=";dS="";sD=".style";
y="document.body.scrollTop";x="document.body.scrollLeft";iW="document.body.clientWidth";iH="document.body.clientHeight"

}


object="stayBotRt";
checkLocationA()
}
movex=0,movey=0,xdiff=0,ydiff=0,ystart=0,xstart=0
function checkLocation(){
 innerX=eval(iW)-240 // place to the right
// innerX=20 // controls the horizontal from the left side of the page

 innerY=eval(iH)-370 // place at the bottom
// innerY=20 // controls the verticle from the top of the page
if (document.layers){innerY-=10;innerX-=10}
yy=eval(y);
xx=eval(x);
ydiff=ystart-yy;
xdiff=xstart-xx;
if ((ydiff<(-1))||(ydiff>(1))) movey=Math.round(ydiff/10),ystart-=movey
if ((xdiff<(-1))||(xdiff>(1))) movex=Math.round(xdiff/10),xstart-=movex


N=(document.layers)?1:0
V=(N) ? 4:5
if (V==4){
eval(dS+object+sD+v+(ystart+innerY));
eval(dS+object+sD+h+(xstart+innerX));
//eval(dS + objectX + sD + v + y);
}
else{
object=document.getElementById('stayBotRt')
object.style.top=ystart+innerY-30
object.style.left=xstart+innerX-30
}

setTimeout("checkLocation()",10)}

function checkLocationA(){ystart=eval(y);xstart=eval(x);}

// END Floating Nav script /////////////////

function loadXML(show)
{
/*
var randomnumber=Math.floor(Math.random()*10000000000000000)
randomnumber= randomnumber+''
//load xml file
// code for IE

show=show+''
if (window.ActiveXObject)
{
	xmlDoc = new ActiveXObject("Microsoft.XMLDOM");
	xmlDoc.async=false;
	xmlDoc.load("/" + show + "/proxy_kan.asp?randomnumber=" + randomnumber);
	getmessage()
}
// code for Mozilla, etc.
else if (document.implementation && document.implementation.createDocument)
{
	xmlDoc= document.implementation.createDocument("","",null);
	xmlDoc.load("/" + show + "/proxy_kan.asp?randomnumber=" + randomnumber);
	xmlDoc.onload=getmessage;
}
else
{
	alert('Your browser cannot handle this script');
}
*/
}

function loadXML1()
{
/*var randomnumber=Math.floor(Math.random()*10000000000000000)
randomnumber= randomnumber+''
//load xml file
// code for IE


if (window.ActiveXObject)
{
	xmlDoc = new ActiveXObject("Microsoft.XMLDOM");
	xmlDoc.async=false;
	xmlDoc.load("home/proxy_kan.asp?randomnumber=" + randomnumber);
	getmessage()
}
// code for Mozilla, etc.
else if (document.implementation && document.implementation.createDocument)
{
	xmlDoc= document.implementation.createDocument("","",null);
	xmlDoc.load("home/proxy_kan.asp?randomnumber=" + randomnumber);
	xmlDoc.onload=getmessage;
}
else
{
	alert('Your browser cannot handle this script');
}
*/
}


