<!--
// JavaScript Document

var startList;
startList = function() {
	if (document.all&&document.getElementById) {
		navRoot = document.getElementById("menu");
		for (i=0; i<navRoot.childNodes.length; i++) {
			node = navRoot.childNodes[i];
			if (node.nodeName=="LI") {
				node.onmouseover=function() {
					this.className+=" over";
				}
				node.onmouseout=function() {
					this.className=this.className.replace(" over", "");
				}
			}
		}
	}
}
window.onload=startList;


function makeLayer(whichLayer,dowith){
  var style2 ='';
  if (document.getElementById){
    style2 = document.getElementById(whichLayer).style;
  }else if (document.all){
    style2 = document.all[whichLayer].style;
  }else if (document.layers){
    style2 = document.layers[whichLayer].style;
  }
	style2.display=dowith;
}


function toggleLayer(whichLayer){
  var style2 ='';
  if (document.getElementById){
    style2 = document.getElementById(whichLayer).style;
  }else if (document.all){
    style2 = document.all[whichLayer].style;
  }else if (document.layers){
    style2 = document.layers[whichLayer].style;
  }
  if(style2.display=='block'){
    style2.display='none';
  }else{
    style2.display='block';
  }
}

function randomString(len){
  var possible = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz1234567890";
  var string = '';
  for(var i=0;i<len;i++){
    string += possible.charAt(Math.floor(Math.random() * 62));
  }
  return string;
}

function fadeOut(id,msec,delay){
	var speed = Math.round(msec / 100);
	var timer = 0;

	for(i = 100; i >= 0; i--) {
		setTimeout("changeOpac(" + i + ",'" + id + "')",(timer * speed + delay));
		timer++;
	}
}

//change the opacity for different browsers
function changeOpac(opacity, id) {
    var object = document.getElementById(id).style;
    object.opacity = (opacity / 100);
    object.MozOpacity = (opacity / 100);
    object.KhtmlOpacity = (opacity / 100);
    object.filter = "alpha(opacity=" + opacity + ")";
} 

function textAreaSize(t) {
a = t.value.split('\n');b=0;
for (x=0;x < a.length; x++) { if (a[x].length >= t.cols) b+= Math.floor(a[x].length/t.cols); }
b+= a.length;
if (b > t.rows) t.rows = b;
}

//-->