// JavaScript Document
	function getScreenResolution()
	{
		if(window.screen.height <=600)
		{
			//resolution is 800X600 or less
			return 800;
		}
		else if(window.screen.height <=768)
		{
			//resolution is 1024X768or less
			return 1024;
		}
		else
		{
			//resolution is bigger than 1024X768
			return 1280;
		}
	}

	function getBrowserType()
	{
		
		if ((navigator.appName).indexOf("Microsoft")!=-1) {
			return "IE"
		}
		else if (navigator.appName=="Netscape") {
			if ((navigator.userAgent).indexOf("Opera")!=-1) {
				return "OP"
			}
			else if(navigator.userAgent.indexOf("Firefox")!=-1) {
				return "FF"
			}
			else if(navigator.userAgent.indexOf("Safari")!=-1) {
				return "SA"
			}
			else { //Netscape Proper
				return "NN"
			}
		}
		else { //browser type is unknown, so assume the biggest, IE. Using else in case future is better detection
			return "IE"
		}				
	}

	function getStyle(el, style) {
	   if(!document.getElementById) return;
	   
		 var value = el.style[toCamelCase(style)];
	   
		if(!value)
			if(document.defaultView)
				value = document.defaultView.getComputedStyle(el, "").getPropertyValue(style);		   
			else if(el.currentStyle)
				value = el.currentStyle[toCamelCase(style)];
		 
		 return value;
	}
	
	function setStyle(objId, style, value) {
		document.getElementById(objId).style[style] = value;
	}
	
	function toCamelCase( sInput ) {
		var oStringList = sInput.split('-');
		if(oStringList.length == 1)    
			return oStringList[0];
		var ret = sInput.indexOf("-") == 0 ? 
		   oStringList[0].charAt(0).toUpperCase() + oStringList[0].substring(1) : oStringList[0];
		for(var i = 1, len = oStringList.length; i < len; i++){
			var s = oStringList[i];
			ret += s.charAt(0).toUpperCase() + s.substring(1)
		}
		return ret;
	}
	
	function increaseWidth(addToWidth, whichDiv){
		var theDiv = document.getElementById(whichDiv);
		var currWidth = parseInt(getStyle(theDiv, "width"));
		var newWidth = currWidth + parseInt(addToWidth);
		setStyle(whichDiv, "width", newWidth + "px");
	}	

	function setWindowVariables(myScreen)
	{			
		var browserType;
		var windowSize;
		var screenHeight;
		var screenWidth;
		var leftWidth;
		var topHeight;
		var bottomHeight;
		var leftDIV;
		var headerDIV;
		var bottomDIV;
											
		//alert("got here!");						
		myScreen.browserType = getBrowserType();
		myScreen.windowSize = getScreenResolution();
		
		alert(myScreen.browserType);
		//alert("WindowSize: " + windowSize);
		if(myScreen.browserType!="IE"){
			myScreen.screenWidth=document.getElementById("testSizeDiv").scrollWidth;
			myScreen.screenHeight=document.getElementById("testSizeDiv").scrollHeight;
		}
		else{		
			//alert('Got to Clent W/H');
			myScreen.screenWidth=document.body.clientWidth;
			myScreen.screenHeight=document.body.clientHeight;			
		}
		
		//alert("Height: " + myScreen.screenHeight + ", Width: " + myScreen.screenWidth);
		//alert("Height: " + screenHeight + ", Width: " + screenWidth);

/*var ContentDiv=document.getElementById("content");
alert("ContentDiv Height: " + ContentDiv.offsetHeight);*/

		/*switch(windowSize)*/
		/*switch(myScreen.windowSize)		
		{
			case 480:
			case 800:
				break;
			case 1024:*/
					/*myScreen.leftWidth = document.getElementById("leftMenu").style.width;
					myScreen.topHeight= document.getElementById("leftMenu").header.height;
					myScreen.bottomHeight=document.getElementById("leftMenu").bottom.height;*/
					
					/*alert("in Switch!");*/				
					leftDIV = document.getElementById("left");
					headerDIV= document.getElementById("header");
					bottomDIV= document.getElementById("bottom");
					/*alert("set DIVs");									
					
					leftWidth = getStyle(leftDIV, "width");
					topHeight= getStyle(headerDIV,"height");
					bottomHeight = getStyle(bottomDIV,"height");*/
					myScreen.leftWidth = getStyle(leftDIV, "width");
					myScreen.topHeight= getStyle(headerDIV,"height");
					myScreen.bottomHeight = getStyle(bottomDIV,"height");
					
					myScreen.leftWidth = parseInt(myScreen.leftWidth);
					myScreen.topHeight = parseInt(myScreen.topHeight);					
					myScreen.bottomHeight = parseInt(myScreen.bottomHeight);
					//alert("Top Height: " + topHeight + ", Left Width: " + leftWidth + ", Bottom Height: " + bottomHeight);
				/*break;
			case 1280:

				break;				
			default:

			//alert('Finished setting vars!');
		}*/
		
		/*myScreen.bodyHeight=myScreen.screenHeight-myScreen.topHeight-myScreen.bottomHeight-myScreen.toolBarHeight;
		myScreen.topWidth = myScreen.screenWidth-myScreen.leftWidth;
		myScreen.indexBodyWidth = myScreen.screenWidth-(myScreen.leftWidth)-myScreen.ScrollBarWidth;
		myScreen.bodyWidth = myScreen.screenWidth-(myScreen.leftWidth)-myScreen.ScrollBarWidth;
		myScreen.optionsBodyWidth = myScreen.screenWidth+(myScreen.leftWidth)-myScreen.ScrollBarWidth;
		myScreen.personalHeight=myScreen.bodyHeight - 40;
		myScreen.listHeight=myScreen.bodyHeight-50;*/
	}
	
/*	function adjustScreenSize()
	{
		var myDiv = document.getElementById("leftMenu");
		var containerDiv = document.getElementById("container");
		var headerDiv = document.getElementById("header");

		//alert(containerDiv.offsetHeight);
		myDiv.style.height=containerDiv.offsetHeight-headerDiv.style.height;
	}	*/

	function initializeScreen(myScreen)
	{
		//alert('Got to Initialize!');
		//alert('Type:' + myScreen.browserType + '  Size:' + myScreen.windowSize);
		//writeCSS(myScreen.browserType,myScreen.windowSize);
		//writeCSS(getBrowserType(), getScreenResolution());
		setWindowVariables(myScreen);
		
		//alert("browser: " + myScreen.browserType + ", Resolution: " + myScreen.windowSize);
		//alert("Height: " + myScreen.screenHeight + ", Width: " + myScreen.screenWidth);
		//alert("Top Height: " + myScreen.topHeight + ", Left Width: " + myScreen.leftWidth + ", Bottom Height: " + myScreen.bottomHeight);

		//modified 8/11 kws
		//adjustLeftHeight(myScreen);

	}			
			
	function adjustLeftHeight(myScreen)
	{	
		//alert('In AdjustLeftHeight!');
		var myContentDIV = document.getElementById("contentBody");
		var myLeftDiv = document.getElementById("left");
		var contentHeight;
		
		if(myScreen.browserType!="IE"){
			contentHeight = getStyle(myContentDIV,"height");
			//contentHeight=stripNumericEndChars(contentHeight);
			//contentHeight=parseInt(contentHeight);
		}
		else{
			//alert("bottomHeight:" + myScreen.bottomHeight);
			//contentHeight=parseInt((myContentDIV.scrollHeight) + parseInt((myScreen.bottomHeight);
			//contentHeight = myContentDIV.scrollHeight + myScreen.bottomHeight;
			//alert("bottomHeight:" + parseInt(myScreen.bottomHeight));			
			contentHeight = myContentDIV.scrollHeight + myScreen.bottomHeight + 12;
		}
		
		//alert('contentHeight: ' + contentHeight);
		myLeftDiv.style.height=contentHeight;
	}

