function externalLinks()
{
	if (!document.getElementsByTagName) return;
	
	var anchors = document.getElementsByTagName("a");
	
	for (var i=0; i<anchors.length; i++) {
		var anchor = anchors[i];
		var relvalue = anchor.getAttribute("rel");
		
		if (anchor.getAttribute("href")) {
			var external = /external/;
			var relvalue = anchor.getAttribute("rel");
			if (external.test(relvalue)) { anchor.target = "_blank"; }
		}
	}
}

function get_all_children(root){
   if(!root)root=document;
   var queue=new Array();
   queue.push(root);
   var ret=new Array();
   while(queue.length>0){
	   element=queue.pop();
	   if(element.tagName=='TD' || element.tagName=='LI') ret.push(element);
	   if(root==document && element.tagName=='A') ret.push(element);
	   if(element.childNodes!=null){
		   if(element.childNodes.length>0){
			   for(i=0;i<element.childNodes.length;i++){
				   queue.push(element.childNodes[i]);
			   }
		   }
	   }
   }
   return ret;
}

window.onload = function(){
	var children = get_all_children();
	
	for (i = 0; i < children.length; i++) {
		children[i].onmouseover = function() {
			this.className += ' active';
		}
		children[i].onmouseout = function() {
			this.className = this.className.replace(' active', '');
		}
	}
	
	externalLinks();
	
	var fot = document.getElementById('footer');
	fot.style.display = "none";
	fot.style.display = "block";
}