
//<![CDATA[

function animClipDown(ref, counter)
{
 var cP = Math.pow(Math.sin(Math.PI*counter/200),0.75);
 ref.style.clip = (counter==100 ?
  ((window.opera || navigator.userAgent.indexOf('KHTML') > -1) ? '':
   'rect(auto, auto, auto, auto)') :
    'rect(0, ' + ref.offsetWidth + 'px, '+(ref.offsetHeight*cP)+'px, 0)');
};

function animFade(ref, counter)
{
 var f = ref.filters, done = (counter==100);
 if (f)
 {
  if (!done && ref.style.filter.indexOf("alpha") == -1)
   ref.style.filter += ' alpha(opacity=' + counter + ')';
  else if (f.length && f.alpha) with (f.alpha)
  {
   if (done) enabled = false;
   else { opacity = counter; enabled=true }
  }
 }
 else ref.style.opacity = ref.style.MozOpacity = counter/100.1;
};

var arrow = null;
if (document.createElement && document.documentElement)
{
 arrow = document.createElement('span');
 arrow.appendChild(document.createTextNode('>'));
 // Feel free to replace the above two lines with these for a small arrow image...
 //arrow = document.createElement('img');
 //arrow.src = 'arrow.gif';
 //arrow.style.borderWidth = '0';

 arrow.className = 'subind';
}


// To create more menus, duplicate this section and make sure you rename your
// menu object to something different; also, activate another <ul> list with a
// different ID, of course :). You can hae as many menus as you want on a page.


//]]>
function goproduct()
{	
	box = document.forms["productQuickSearch"].productselect;
	destination = box.options[box.selectedIndex].value;
	if (destination) location.href = destination;
}

function goproducttype()
{
	box = document.forms["productQuickSearch"].producttypeselect;
	destination = box.options[box.selectedIndex].value;
	if (destination) location.href = destination;
}

function openClothing(page)
{
	var n=open(page,'ExtremeClothing','width=640,height=480,status=no,menubar=no,scrollbars=auto,resizable=yes');
}
function openWin(page)
{
	var n=open(page,'Gatekeeper','width=660,height=500,status=no,menubar=no,scrollbars=auto,resizable=yes');
}
function openMailWin(page)
{
	var n=open(page,'ExtremeCCTV','width=600,height=550,status=no,menubar=no,scrollbars=auto,resizable=yes');
}
function openBOD(page)
{
	var n=open(page,'Gatekeeper','width=360,height=290,status=no,menubar=no,scrollbars=no,resizable=no');
}
function openFAQ(page)
{
	var n=open(page,'ExtremeCCTVFAQ','width=300,height=300,status=no,menubar=no,scrollbars=auto,resizable=yes');
}
function openPDF(page)
{
	var n=open(page,'Gatekeeper','width=400,height=500,status=no,menubar=no,scrollbars=auto,resizable=yes');
}
function openCorp(page)
{
	var n=open(page,'ExtremeCCTV','width=600,height=550,status=no,menubar=yes,scrollbars=yes,resizable=yes');
}
function checkloginForm() {

        if (document.login.emailaddress.value=="") {
	  alert("Please enter an email address!");
          document.login.emailaddress.focus();
          return;
	}
        if (document.login.password.value=="") {
	  alert("Please enter a password!");
          document.login.password.focus();
          return;
	}

     if (document.login.emailaddress.value.indexOf('@',0) == -1 || document.login.emailaddress.value.indexOf('.',0) == -1) {
       alert("Please enter a valid email address");
       document.login.emailaddress.focus();
       return;
     }

document.login.submit();   
}

function checkloginFormtwo() {

        if (document.logintwo.emailaddress.value=="") {
	  alert("Please enter an email address!");
          document.logintwo.emailaddress.focus();
          return;
	}
        if (document.logintwo.password.value=="") {
	  alert("Please enter a password!");
          document.logintwo.password.focus();
          return;
	}

     if (document.logintwo.emailaddress.value.indexOf('@',0) == -1 || document.logintwo.emailaddress.value.indexOf('.',0) == -1) {
       alert("Please enter a valid email address");
       document.logintwo.emailaddress.focus();
       return;
     }

document.logintwo.submit();   
}



