
/*
Browser Sniffer Script-
© Eddie Traversa (nirvana.media3.net)
To add more shock to your site, visit www.DHTMLShock.com
*/
var isMac = false;

function platformSniffer(macURL,os2URL,linuxURL,winURL) {
	var agt=navigator.userAgent.toLowerCase();
	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_mac    = (agt.indexOf("mac")!=-1); 
	var is_os2   = ((agt.indexOf("os/2")!=-1) || 
                    (navigator.appVersion.indexOf("OS/2")!=-1) ||   
                    (agt.indexOf("ibm-webexplorer")!=-1));
	
	var is_linux = (agt.indexOf("inux")!=-1);
	var is_win   = ((agt.indexOf("win")!=-1) || (agt.indexOf("16bit")!=-1) );
	var is_win95 = ((agt.indexOf("win95")!=-1) || (agt.indexOf("windows 95")!=-1));
	var is_win16 = ((agt.indexOf("win16")!=-1) || 
			(agt.indexOf("16bit")!=-1) || (agt.indexOf("windows 3.1")!=-1) || 
			(agt.indexOf("windows 16-bit")!=-1) );  
   
   var is_win31 = ((agt.indexOf("windows 3.1")!=-1) || (agt.indexOf("win16")!=-1) ||
                    (agt.indexOf("windows 16-bit")!=-1));
    var is_win98 = ((agt.indexOf("win98")!=-1) || (agt.indexOf("windows 98")!=-1));
    var is_winnt = ((agt.indexOf("winnt")!=-1) || (agt.indexOf("windows nt")!=-1));
    var is_win32 = (is_win95 || is_winnt || is_win98 || 
                    ((is_major >= 4) && (navigator.platform == "Win32")) ||
                    (agt.indexOf("win32")!=-1) || (agt.indexOf("32bit")!=-1));
					
					
	if (is_mac) { // Macintosh
	//location.href = macURL;
		isMac = true;
	 } else if (is_os2) { // OS2
  // location.href = os2URL;
   } else if (is_linux) { // Linux
   	//location.href = linuxURL;
   } else if (is_win || is_win95 || is_win98 || is_winnt || is_win31 || is_win32 || is_win16) { 
 //  document.triggers.style.left='116px';
    }
   }

function repositionNav()
{


// The code block below is from:
// http://www.quirksmode.org/viewport/compatibility.html
// It will find the browser window's width depending on
// the correct browser property.

// -- Start --
var x,y,theType;
if (document.documentElement && document.documentElement.clientHeight)
	// Explorer 6 Strict Mode
{
	x = document.documentElement.clientWidth;
	y = document.documentElement.clientHeight;
	theType = "docElem";
}
else if (document.body) // other Explorers
{
	x = document.body.clientWidth;
	y = document.body.clientHeight;
	theType = "docBody";
}
// -- End --


//tempLeft = (document.body.clientWidth / 2) -379
//document.all.triggers.style.left=tempLeft
tempLeft = (x/2)-238

if(document.getElementById('triggers') != null){

document.getElementById('triggers').style.left = tempLeft
}

}

function loadfunctions()
{
platformSniffer('mac.html','OS2.html','Linux.html','Windows.html')
repositionNav()

}

function Alert()
{
	tempstr=Verify()

	if(tempstr=="none")
		{
			document.contactform.submit()
		}
	else
		{
			window.alert (tempstr);
		}
}
function Verify()
{

        if (document.contactform.inPageName.value == "")
        {
            promptSTR = "Please Enter a Valid Name.";
            return promptSTR
        }


        else if (document.contactform.inPageEmail.value == "")
		        {
		            promptSTR = "Please Enter a Valid E-mail Address.";
		            return promptSTR
        }
        else if (document.contactform.inPageMsg.value == "")
				{
					promptSTR = "Please Enter a Message.";
					return promptSTR
        }
        else
				{
					promptSTR = "none";
		            return promptSTR
		        }
}

function printpage() {
window.print();  
}
