
function showInline(ID) {
	document.getElementById(ID).style.display = 'inline';
}
function showBlock(ID) {
	document.getElementById(ID).style.display = 'block';
}
function hideElement(ID) {
	document.getElementById(ID).style.display = 'none';
}
function focusElement(ID) {
	document.getElementById(ID).focus();
}

// a javascript "sleep" function
// gap specifies the sleep time in miliseconds
function delay(gap){
	var then,now;
	then=new Date().getTime();
	now=then;
	while((now-then)<gap) {
		now=new Date().getTime();
	}
}

// http://www.sitepoint.com/article/standards-compliant-world
function externalLinks() { 
 if (!document.getElementsByTagName) return; 
 var anchors = document.getElementsByTagName("a"); 
 for (var i=0; i<anchors.length; i++) { 
   var anchor = anchors[i]; 
   if (anchor.getAttribute("href") && 
       anchor.getAttribute("rel") == "external") 
     anchor.target = "_blank"; 
 } 
} 
window.onload = externalLinks;
