startList = function() {
	if (document.all&&document.getElementById) {
		navRoot = document.getElementById("nav");
		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;

/*
######################################################################################
				POPUP WINDOW on the center of the screen
######################################################################################
*/

var win = null;
function newWindow(mypage,myname,w,h,features) {
  var winl = (screen.width-w)/2;
  var wint = (screen.height-h)/2;
  if (winl < 0) winl = 0;
  if (wint < 0) wint = 0;
  var settings = 'height=' + h + ',';
  settings += 'width=' + w + ',';
  settings += 'top=' + wint + ',';
  settings += 'left=' + winl + ',';
  settings += features;
  win = window.open(mypage,myname,settings);
  win.window.focus();
}

/*
###############################################################################
BELOW IS THE CODE FOR RECONSTRUCTING EMAIL ADDRESSES TO INHIBIT ADDRESS HARVESTING. 
THE CONVENSION FOR THIS WITHIN THE HTML CODE IS AS FOLLOWS:
<a href="javascript:sendMailTo('username','indiana','edu')">username [at] indiana [dot] edu</a> 
###############################################################################
*/

function sendMailTo(username, domain, extension){
	var mailtostring = 'mai' + 'lto:' + username + '@' + domain + '.' + extension;
	window.location.replace(mailtostring);
}

/*
###############################################################################
BELOW IS THE CODE TO DISPLAY WHEN THE PAGE WAS LAST UPDATED.
###############################################################################
*/

function makeArray() { 
for (i = 0; i < makeArray.arguments.length; i++) 
  this[i + 1] = makeArray.arguments[i]; 
}

function lastModified(){
	var modifiedMonth = new makeArray('January','February','March','April',
							  'May','June','July','August','September',
							  'October','November','December');
	var modifiedDate = new Date(document.lastModified); 
	document.write('<i>Last modified</i>: ' + modifiedMonth[modifiedDate.getMonth() + 1] + ' ' + 
									  modifiedDate.getDate() + ', ' + 
									  modifiedDate.getFullYear());
}


/*
###############################################################################
BELOW IS THE CODE TO DISPLAY THE COPYRIGHT DISCLAIMER WITH THE CURRENT YEAR 
IN THE FOOTER OF EACH HTML DOCUMENT.
###############################################################################
*/

function displayCopyrightInfo(){
	var dateObj = new Date();
	var year = dateObj.getYear();
	if (year < 2000){
		year = year + 1900; // Y2K Fix, Isaac Powell - http://onyx.idbsu.edu/~ipowell
	}
	document.write(year);
}


/*
###############################################################################
BELOW IS THE CODE TO DISPLAY AND HIDE SPECIFIC DIVs.
###############################################################################
*/


function toggle(a, b) {
	if (document.getElementById) {
		document.getElementById(a).style.display=(b)?"block":"none";
        }
}
