//This is all original code developed by me, Matthew Woller, for mine and Levi Blackstone's HTML Final Report
//for the AiS SuperComputing Challenge.

// this will show the indicated span or div.

function showIt(id){
	document.all[id].style.visibility="visible";
	document.all[id].style.filter = "Alpha(opacity=75)";
}

//this will hide the indicated span or div.

function hideIt(id){
	document.all[id].style.visibility = "hidden";
}
function br(){
	document.write("<BR>");
}
function span(){
	document.write("</span>");
}
//this allows the user to check if their computer is able to view the page correctly and if they need to update
//their browser.

function noticefunc(){
	wide = screen.width;
	tall = screen.height;
	browseName = navigator.appName;
	browseVer = navigator.appVersion;
	alerttext = "This web site is best seen with Internet Explorer 4.0(6.0 reccomended) or higher, with the screen values set to 1024 x 768, on  OS Windows 98 or better, and with the Internet Explorer window maximized.  Your current values are:\n\n     Screen width:"+wide+"\n     Screen height:"+tall+"\n     Browser:"+browseName+", version "+browseVer+"\n\n\n";
	if (wide < 1024 || tall < 768){
		alerttext += "   YOUR SCREEN VALUES WILL NOT WORK EFFECIENTLY WITH THIS PAGE!   \n\n";
		alert(alerttext);
	}
	else {}
	if (eval(browseVer.substring(0,2)) >= 4){}
	else {
		alerttext += "   YOUR BROWSER VERSION IS NOT HIGH ENOUGH TO DISPLAY THIS WEB PAGE CORRECTLY!   \n\n";
		alert(alerttext);
	}
}
//these change the background color and foreground color for the selected span, div, or whatever.
/*
 *
 *	This function is basically the core of this whole Script File.
 *	It creates a <span>, or <a> depending on certain values that are passed.
 *	"menulevel" tells the function what depth of the menu the element is.
 *	"linkadd" is a boolean value that tells whether or not the <a> will be a link.
 *	"linkloc" is only used if "linkadd" is true.  It tells the address of the link destination.
 *	"linktext" is only used if "linkadd" is true.  It tells the text for the <a>.
 *	"willext" tells if a level 2 menu item will extend w/ another item.
 *	"extname" tells the <span> that will extend off of the current one.
 *	The entire function builds the key components of the moving menu and activates it and the clock.
 *
 *
*/
fore = "black";
border = "dodgerblue";
backg = "white";

function createitem(menulevel,linkadd,linkloc,linktext,willext,extname){
	text2write="";
	if (menulevel == 3){
		if (linkadd){
			text2write =     '<a href="'+linkloc+'"target="content"style="color:'+fore+';border:'+border+' solid 2px;font-size:18px;background-color:'+backg+'onMouseOver="this.style.background=\''+fore+'\';this.style.color=\''+backg+'\'"onMouseOut="this.style.background=\''+backg+'\';this.style.color=\''+fore+'\'">'+linktext+'</a>';
		}
	}
	else if (menulevel == 2){
		if (linkadd){
			text2write +=    '<a href="'+linkloc+'"target="content"style="color:'+fore+';border:'+border+' solid 2px;font-size:18px;width:150px;background-color:'+backg+'"onMouseOver="this.style.background=\''+fore+'\';this.style.color=\''+backg+'\'"onMouseOut="this.style.background=\''+backg+'\';this.style.color=\''+fore+'\'">'+linktext+'</a>';
		}
		else {
			text2write +=   '<a style="color:'+fore+';border:'+border+' solid 2px;font-size:18px;background-color:'+backg+'"onMouseOver="this.style.background=\''+fore+'\';this.style.color=\''+backg+'\'"onMouseOut="this.style.background=\''+backg+'\';this.style.color=\''+fore+'\'">'+linktext+'</a>';
		}
	}
	else if (menulevel == 1){
		if (willext){
			text2write =     '<span onMouseOver="showIt(\''+extname+'\');this.style.background=\''+fore+'\';this.style.color=\''+backg+'\'"onMouseOut="hideIt(\''+extname+'\');this.style.background=\''+backg+'\';this.style.color=\''+fore+'\'"style="position:relative;top:0px;left:0px;background-color:'+backg+';color:'+fore+';font-size:18px;width:150px">';
		}
	}
	document.write(text2write);
}
createitem(2,true,"content.htm","Home",false,null);
br()
br()
createitem(2,true,"summary.htm","Executive Summary",false,null);
br()
br()
createitem(1,false,null,null,true,"introductionlist")
document.write('<span style="font-size:18px;border:'+border+' solid 2px;width:150px">Introduction -&gt;</span>')
document.write('<span id="introductionlist"style="position:absolute;left:150px;border:'+border+' solid 2px;font-size:18px;width:75px;z-index:8">');
createitem(2,true,"intro1.htm","Page 1",false,null);
br()
createitem(2,true,"intro2.htm","Page 2",false,null);
span()
span()
br()
br()
createitem(2,true,"processesinvolved.htm","Processes",false,null);
br()
br()
createitem(2,true,"model.htm","The Model",false,null);
br()
br()
createitem(1,false,null,null,true,"resultslist");
document.write('<span style="font-size:18px;border:'+border+' solid 2px;width:150px">Results -&gt;</span>')
document.write('<span id="resultslist"style="position:absolute;left:150px;border:'+border+' solid 2px;font-size:18px;width:75px;z-index:8">');
createitem(2,true,"results1.htm","Page 1",false,null);
br()
createitem(2,true,"results2.htm","Page 2",false,null);
br()
createitem(2,true,"results3.htm","Page 3",false,null);
br()
createitem(2,true,"results4.htm","Page 4",false,null);
br()
createitem(2,true,"results5.htm","Page 5",false,null);
br()
createitem(2,true,"results6.htm","Page 6",false,null);
span()
span()
br()
br()
createitem(2,true,"conclusions.htm","Conclusions",false,null);
br()
br()
createitem(2,true,"recommendations.htm","Recommendations",false,null);
br()
br()
createitem(2,true,"acknowledgements.htm","Acknowledgements",false,null);
br()
br()
createitem(2,true,"references.htm","References",false,null);
br()
br()
createitem(1,false,null,null,true,"appendixlist");
document.write('<span style="font-size:18px;border:'+border+' solid 2px;width:150px">Appendices -&gt;</span>')
document.write('<span id="appendixlist"style="position:absolute;left:150px;border:'+border+' solid 2px;font-size:18px;width:75px;z-index:8">');
createitem(2,true,"appendixA.htm","Appendix A",false,null);
br()
createitem(2,true,"appendixB.htm","Appendix B",false,null);
br()
createitem(2,true,"appendixC.htm","Appendix C (code)",false,null);
span()
span()
br()
br()
createitem(1,false,null,null,true,"otherlist");
document.write('<span style="font-size:18px;border:'+border+' solid 2px;width:150px">Others... -&gt;</span>')
document.write('<span id="otherlist"style="position:absolute;left:150px;border:'+border+' solid 2px;font-size:18px;width:75px;z-index:8">');
createitem(2,true,"abstract.htm","Abstract",false,null);
br()
createitem(2,true,"interimreport.htm","Interim Report",false,null);
br()
createitem(2,true,"whatais.htm","About AiS",false,null);
span()
span()

document.all.introductionlist.style.visibility="hidden";
document.all.resultslist.style.visibility = "hidden";
document.all.appendixlist.style.visibility = "hidden";
document.all.otherlist.style.visibility = "hidden";




