var Nets=true;
var ie=false;

if (self.parent.frames.length) self.parent.location=document.location;

if (document.all) {
  ie=true;
  Nets=false;
}

if(Nets) {
  window.onresize = resizenet;
  window.saveInnerWidth = window.innerWidth;
  window.saveInnerHeight = window.innerHeight;
}

function resizenet() {
  if (saveInnerWidth < window.innerWidth ||
    saveInnerWidth > window.innerWidth ||
    saveInnerHeight > window.innerHeight || 
    saveInnerHeight < window.innerHeight ) {
    self.history.go(0);
  }
}

var where="images/";

function swaper(which){
  eval("document.images['"+which+"'].src='"+where+"g_"+which+".gif'");
}

function unswaper(which){
  eval("document.images['"+which+"'].src='"+where+"l_"+which+".gif'");
}

function rollover(whichroll, tbcolor, txcolor){
  if(!Nets){
    if(tbcolor){
      eval("document.all['tb_"+whichroll+"'].bgColor='"+tbcolor+"'");
	}
	if(txcolor){
      eval("document.all['tx_"+whichroll+"'].style.color='"+txcolor+"'");
	}
  }
}

var WhereLayer;
var WhereStyle; 
var x;
var y;
var CurrMenu="";
var CurrX;
var CurrY;
var CurrWidth;
var CurrHeight;

function MouseMove(e){
  if(ie){
    x=event.x;
    y=event.y+document.body.scrollTop;
  }
  if(Nets){
    x=e.pageX;
    y=e.pageY+15+pageYOffset;
  }
  
  if (CurrMenu!=""){
    if ((x<CurrX-10)||(x>CurrX+CurrWidth)||(y<CurrY)||(y>CurrY+CurrHeight)){
      eval(WhereLayer + "['"+CurrMenu+"']" + WhereStyle+".visibility='hidden'");
      if((!Nets)&&(CurrMenu!="faq")){
        eval(WhereLayer + "['tb_"+CurrMenu+"'].bgColor='#FFCE31'");
        eval(WhereLayer + "['tx_"+CurrMenu+"']" + WhereStyle + ".color='#082173'");
      }
      CurrMenu="";
    }
  }
}

if (Nets) {
  document.onmousemove = MouseMove;
  document.captureEvents(Event.MOUSEMOVE);
  WhereLayer = "document.layers";
  WhereStyle = ""; 
} else {
  document.onmousemove = MouseMove;
  WhereLayer = "document.all";
  WhereStyle = ".style"; 
}

function showmenu(WhichMenu,wid,hei){
  if (CurrMenu!="") {
    eval(WhereLayer + "['"+CurrMenu+"']" + WhereStyle + ".visibility='hidden'");
	if((!Nets)&&(CurrMenu!="faq")){
      eval(WhereLayer + "['tb_"+CurrMenu+"'].bgColor='#FFCE31'");
      eval(WhereLayer + "['tx_"+CurrMenu+"']" + WhereStyle + ".color='#082173'");
	}
  }
  eval(WhereLayer + "['"+WhichMenu+"']" + WhereStyle + ".visibility='visible'");
  if((!Nets)&&(WhichMenu!="faq")){
    eval(WhereLayer + "['tb_"+WhichMenu+"'].bgColor='#6B739C'");
    eval(WhereLayer + "['tx_"+WhichMenu+"']" + WhereStyle + ".color='#FFFFFF'");
  }
  CurrMenu=WhichMenu;
  CurrX=parseInt(eval(WhereLayer + "['"+WhichMenu+"']" + WhereStyle + ".left"));
  CurrY=parseInt(eval(WhereLayer + "['"+WhichMenu+"']" + WhereStyle + ".top"))-70;
  CurrWidth=wid;
  CurrHeight=hei+60;
}

if (Nets) {
  document.writeln('<style type="text/css">');
  document.writeln('.mainlinks {font-size:10px}');
  document.writeln('.mainlinkswhite {font-size:10px}');
  document.writeln('.copy {font-size:10px}');
  document.writeln('.questions {font-size:11px;}');
  document.writeln('.dropdown {font-size:11px;}');
  document.writeln('.rightblue {font-size:11px;}');
  document.writeln('.orangetxt {font-size:12px;}');
  document.writeln('</style>');
}
