




/*
     FILE ARCHIVED ON 4:50:35 Jul 9, 2007 AND RETRIEVED FROM THE
     INTERNET ARCHIVE ON 9:58:28 Aug 2, 2011.
     JAVASCRIPT APPENDED BY WAYBACK MACHINE, COPYRIGHT INTERNET ARCHIVE.

     ALL OTHER CONTENT MAY ALSO BE PROTECTED BY COPYRIGHT (17 U.S.C.
     SECTION 108(a)(3)).
*/

function set_errorfiled(name,message){
	var el = document.getElementById(name);	
	el.className = 'formError';
	var em = document.createElement('em');
	em.innerHTML = message;
	em.className='formError';
	el.parentNode.appendChild(em);
}
/*
function addEvent(elm, evType, fn, useCapture)
{
if(elm.addEventListener)
  {
  elm.addEventListener(evType, fn, useCapture);
  return true;
  }
else if (elm.attachEvent)
  {
  var r = elm.attachEvent('on' + evType, fn);
  return r;
  }
else
  {
  elm['on' + evType] = fn;
  }
}
*/

// removes the square border that IE
// insists on adding to checkboxes and radio
function removeCheckBoxBorders()
{
var el = document.getElementsByTagName("input");
if(count=el.length) {
	for (i=0;i<count;i++)
	  {
	  var type = el[i].getAttribute("type");
	  if((type=="checkbox")||(type=="radio"))
	    {
	   el[i].className = "none";
	    }
	  }
}

}
function showDetailed (element) {
	el=element.parentNode.parentNode.parentNode.parentNode;
	if (el.className!='display') {
		el.className='display';
	} else {
		el.className='hide';		
	}
}
function sh(el,value,id) {
	if (el.value == value) {
		document.getElementById(id).disabled = false;
		document.getElementById(id).className= "";
		document.getElementById(id).focus();
	} else {
		document.getElementById(id).disabled = true;
		document.getElementById(id).className= "hdn";	
	}
	
}

function decode64(inp)
{
	var clearText = atob(inp);
	return clearText;	
}

function hoverState(id, tag) {
	if (!/MSIE (5|6)/.test(navigator.userAgent)) return;
	el = document.getElementById(id);
	blck = el.getElementsByTagName(tag.toUpperCase());
	for (a=0;a<blck.length; a++) {
		blck[a].onmouseover =  new Function("this.className = this.className.replace(/( ?hover)+/ig,'')+' hover';");
		blck[a].onmouseout =  new Function("this.className = this.className.replace(/( ?hover)+/ig,'');");
	}
}


function hoverStateClass(tag, class) {
	
	
	
	if (!/MSIE (5|6)/.test(navigator.userAgent)) return;
	el = document.getElementsByTagName(tag.toUpperCase());
	for (a=0;a<el.length; a++) {
		if (el[a].className.match(class)) {
			el[a].onmouseover =  new Function("this.className = this.className.replace(/( ?hover)+/ig,'')+' hover';");
			el[a].onmouseout =  new Function("this.className = this.className.replace(/( ?hover)+/ig,'');");
		}
	}
}



function ale(func){
	var oldonload = window.onload;
	if (typeof window.onload != 'function'){
    	window.onload = func;
	} else {
		window.onload = function(){
		oldonload();
		func();
		}
	}
}

function onLoad(){
	hoverState('comments', 'BLOCKQUOTE');
	hoverStateClass('DIV', 'gauge?');
	removeCheckBoxBorders();
}


ale(onLoad);

