<!-- 
// Owner
// Austin Extreme
// -----------------------------------------------
// Sitewide Javascript
// -----------------------------------------------
/*
 *******************************************************
 * * * * * * * * - - W A R N I N G - - * * * * * * * * *
 *******************************************************
 -------------------------------------------------------
 |  All scripting contained herein and that contained  |
 |  in the same directory location as this file or     |
 |  script including this script are the property and  |
 |  creation of Austin Extreme.  If you wish to use    |
 |  and or copy that property in part or in whole,     |
 |  please request permission to do so by sending an   |
 |  e-mail request to codeuse@austinextreme.com.       |
 |  Then, wait for a confirmation reply letter         |
 |  granting such permission before preceding to       |
 |  use and/or copy theabove described property.       |
 |  Copyright Zigami, 2001.                            |
 -------------------------------------------------------
*/
//~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
// Netscape Resize Fix
// fixes well documented bug that blows page up after resize
if (document.layers)
	{
	origWidth = innerWidth;
	origHeight = innerHeight;
	}
function reDo()
	{
	if (innerWidth != origWidth || innerHeight != origHeight)
	location.reload();
	}
if (document.layers) onresize = reDo;
//~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~


//~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
//error stop
function stopError()
	{
	return true;
	}
window.onerror = stopError;
//~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~


//~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
// Right Mouse Button Disable. IE 4+ and NS 4+
//var message="";
//function clickIE()
//{
//	if (document.all) {(message);return false;}
//}
//function clickNS(e) 
//{
//	if (document.layers||(document.getElementById&&!document.all)) 
//	{
//		if (e.which==2||e.which==3) {(message);return false;}
//	}
//}
//	if (document.layers) 
//	{
//		document.captureEvents(Event.MOUSEDOWN);document.onmousedown=clickNS;
//	}
//	else
//	{
//		document.onmouseup=clickNS;document.oncontextmenu=clickIE;
//		}
//document.oncontextmenu=new Function("return false")
//~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~


//~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
// Global Function for scrolling a frame
function scrollme(x)
{
	var x;
	top.frames("frmmain").document.frames("frmnav").scrollit(x);
}
//~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~



//~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
// Gets random images for display
function getRandomImageD(style) {
	switch (style) {
		case "frontdoor" : 
			var i = Math.floor(frontdoor.length*Math.random());
			return frontdoor[i];
		case "innerdoor" :
			var i = Math.floor(innerdoor.length*Math.random());
			return innerdoor[i];
		case "workarea" :
			var i = Math.floor(workarea.length*Math.random());
			return workarea[i];
	}	
}
//~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~


//~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
// Browser and Ops System Check
// Ops System Check
function checkOS() {
  if(navigator.userAgent.indexOf('Linux') != -1)
    { var OpSys = "Linux"; }
  else if((navigator.userAgent.indexOf('Win') != -1) &&
  (navigator.userAgent.indexOf('95') != -1))
    { var OpSys = "Windows95"; }
  else if(navigator.userAgent.indexOf('Win') != -1)
    { var OpSys = "Windows3.1 or NT"; }
  else if(navigator.userAgent.indexOf('Mac') != -1)
    { var OpSys = "Macintosh"; }
  else { var OpSys = "other"; }
  return OpSys;
}
var OpSys = checkOS();
// convert all characters to lowercase to simplify testing 
var agt=navigator.userAgent.toLowerCase(); 
// *** BROWSER VERSION *** 
// Note: On IE5, these return 4, so use is_ie5up to detect IE5. 
var is_major = parseInt(navigator.appVersion); 
var is_minor = parseFloat(navigator.appVersion); 
var is_nav  = ((agt.indexOf('mozilla')!=-1) && (agt.indexOf('spoofer')==-1) && (agt.indexOf('compatible') == -1) && (agt.indexOf('opera')==-1) && (agt.indexOf('webtv')==-1)); 
var is_nav2 = (is_nav && (is_major == 2)); 
var is_nav3 = (is_nav && (is_major == 3)); 
var is_nav4 = (is_nav && (is_major == 4)); 
var is_nav4up = (is_nav && (is_major >= 4)); 
var is_navonly = (is_nav && ((agt.indexOf(";nav") != -1) || (agt.indexOf("; nav") != -1)) ); 
var is_nav5 = (is_nav && (is_major == 5)); 
var is_nav5up = (is_nav && (is_major >= 5)); 
var is_ie   = (agt.indexOf("msie") != -1); 
var is_ie3  = (is_ie && (is_major < 4)); 
var is_ie4  = (is_ie && (is_major == 4) && (agt.indexOf("msie 5.0")==-1) ); 
var is_ie4up  = (is_ie  && (is_major >= 4)); 
var is_ie5  = (is_ie && (is_major == 4) && (agt.indexOf("msie 5.0")!=-1) ); 
var is_ie5up  = (is_ie  && !is_ie3 && !is_ie4); 
var isIE4, isIE4PC, isNav4PC, isNav4, isNav3;

if (is_ie4 || is_ie4up || is_nav5 || is_nav5up) 
{
	isIE4 = true;
	if (OpSys != "Macintosh") {
		isIE4PC = true;
	} 
} else if (is_nav4) {
	isNav4 = true;
	if (OpSys != "Macintosh") {
		isNav4PC = true;
	} 
} else if  (is_nav) {
	isNav3 = true;	
    }
//~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~


//~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
//rollover script
function swap(imgDocID,imgObjName) 
{
	if (is_ie4 || is_ie4up || is_nav5 || is_nav5up)
    {
	document.images[imgDocID].src = eval(imgObjName + ".src")
    }
}
//~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~


//~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
// Popup window
self.name = "parentWin";
function  popWindow(url,name,x,y,s,w, h) 
{
	popupWin = window.open(url,"name",'scrollbars='+s+',menubar=0,toolbar=0,location=0,resizable=0,width='+w+',height='+h+'');
	popupWin.moveTo(x,y);
	popupWin.focus();
};
//~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~


//~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
// Removes Undesirables Characters
function rem_obj(obj)
	{
	obj.value = obj.value.replace(/'/g, "");
	obj.value = obj.value.replace(/"/g, "");
	obj.value = obj.value.replace(/;/g, "");
	obj.value = obj.value.replace(/</g, "");
	obj.value = obj.value.replace(/>/g, "");
	}
//~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~


/*
if (is_ie4 || is_ie4up || is_nav5 || is_nav5up)
{
//Rollover values
home_over = new Image(85,16);
home_over.src = "/images/sitewide/home_over.gif";
home_up = new Image(85,16);
home_up.src = "/images/sitewide/home_up.gif";

}
*/
-->
