	
	function writeMenu( sel ) {
	
		var text;
		var s1 = "";
		var s2 = "";
		var s3 = "";
		var s4 = "";	
		var s5 = "";
		var s6 = "";
		var s7 = "";	
		var s8 = "";
		var s9 = "";

		
		switch ( sel ) {
			case "home":	s1 = "id='selected'";
			break
			case "about":	s2 = "id='selected'";
			break
			case "articles": s3 = "id='selected'";
			break		
			//case "calendar": s4 = "id='selected'";
			//break
			case "calculator": s5 = "id='selected'";
			break
			//case "resources": s6 = "id='selected'";
			//break
			case "links":	s7 = "id='selected'";
			break
			case "pastevents":	s8 = "id='selected'";
		}
		
		
		text =  '<div id="banner" align="center"><h1>Taking local, global, and municipal action against global warming</h1></div>\n';
		text += '	<div id="logo">\n';
		text += '		<img src="images/LexGWAC.gif">\n';
		text += '   <div align="center"><font color="#797"><h1>of<br>Lexington<br>Massachusetts</h1></font></div>\n';
		text += '	<br><br>\n';
		
		text += '   <div id="hMenu">\n';
		text += '      <ul>\n';
		text += '         <li ' + s1 + '><a href="index.html">Home</a></li>\n';
		text += '         <li ' + s2 + '><a href="About.html">About</a></li>\n';
		text += '         <li ' + s3 + '><a href="Articles.html">Articles</a>\n';
//		text += '         <li ' + s4 + '><a href="Calendar.html">Calendar</a>\n';
		text += '         <li ' + s5 + '><a href="Calculator2.html\" target="_blank\">Calculator</a></li>\n';
//		text += '         <li ' + s6 + '><a href="Resources.html">Resources</a>\n';
		text += '         <li ' + s7 + '><a href="Related.html">Links</a>\n';
		text += '         <li ' + s8 + '><a href="PastEvents.html">Past Events</a>\n';
		text += '      </ul>\n';
		text += '   </div>\n';
		text += '  </div>\n';
		
		//return text;
		document.write( text );
	}
	
	function writeLogo() {
	

		
		
		text =  '<div id="banner_calc" align="center"><h1>Taking local, global, and municipal action against global warming</h1></div>\n';
		//text += '	<div id="logo">\n';
		//text += '		<img src="images/LexGWAC.gif">\n';
		//text += '	<br/>\n';

		//text += '  </div>\n';
		
		//return text;
		document.write( text );
	}
	
	function writeFooterClose( footer, date ) {
		var text;
		
		if ( footer == "" ) {
			text  = '<div id="footer">Page Design by <a href="mailto:tomboulet@aol.com">Tom Boulet</a><br/>\n';
		} else {
			text  = '<div id="footer">' + footer + '</a><br/>\n';
		}
		
		text += 'Last updated on ' + date + '</div>\n';
		
		document.write( text );
		document.close();
	}
	
		
