/*
1 start, 2 end
3 general info
4, 5 trans
6, 7 office elec
8, 9 home elec
10, 11 office lighting
12, 13 home lighting
14, 15 office heat
16, 17 home heat



*/

function buttons(ep)
{
	var start_string = "calculateEmissionsElec_onclick(1);";
	var end_string = "calculateEmissionsElec_onclick(2);";
	//document.write('<p><input TYPE="reset" VALUE="Reset" NAME="reset1"><input TYPE="button" VALUE="Continue" NAME=button3 onclick="gatherGeneralData_onclick()"></form>');
	//document.write('<p>');
	document.write('&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp');
	document.write('<INPUT TYPE="button" VALUE="Return to Start" NAME=button3 onclick=', start_string, '>');
	document.write('<INPUT TYPE="button" VALUE="Skip to Final Results" NAME=button4 onclick=', end_string, '>');
	
}

function buttons2( click_string )
{
	var start_string = "window.location='introduction.htm'";
	var end_string = "window.location='results.htm'";

	document.write('<FORM NAME=form999>');
	document.write('<INPUT TYPE="button" VALUE="Previous" NAME=button2 onclick="window.history.go(-1)">');
	document.write('<INPUT TYPE="button" VALUE="Next" NAME=button3 onclick=', click_string, '>');
	document.write('&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp');
	document.write('<INPUT TYPE="button" VALUE="Return to Start" NAME=button3 onclick=', start_string, '>');
	document.write('<INPUT TYPE="button" VALUE="Skip to Final Results" NAME=button3 onclick=', end_string, '>');
	document.write('</FORM>');
}

function star( x, y )
{
 if( x == y )
  return "*";
 else
  return "";
}

function menu(page)
{





	/*var start_string = "calculateEmissionsElec_onclick(1);";
	var end_string = "calculateEmissionsElec_onclick(2);";
	var general_info = "calculateEmissionsElec_onclick(3);";
	var trans_ntw = "calculateEmissionsElec_onclick(4);";
	var trans_tw = "calculateEmissionsElec_onclick(5);";
	var elec_off_ntw = "calculateEmissionsElec_onclick(6);";
	var elec_off_tw = "calculateEmissionsElec_onclick(7);";
	var elec_home_ntw = "calculateEmissionsElec_onclick(8);";
	var elec_home_tw = "calculateEmissionsElec_onclick(9);";
	var light_off_ntw = "calculateEmissionsElec_onclick(10);";
	var light_off_tw = "calculateEmissionsElec_onclick(11);";
	var light_home_ntw = "calculateEmissionsElec_onclick(12);";
	var light_home_tw = "calculateEmissionsElec_onclick(13);";
	var heat_off_ntw = "calculateEmissionsElec_onclick(14);";
	var heat_off_tw = "calculateEmissionsElec_onclick(15);";
	var heat_home_ntw = "calculateEmissionsElec_onclick(16);";*/

	document.write('<map name="nav">');
	document.write('<area shape="rect" coords="0,0,75,78" href="javascript:calculateEmissionsElec_onclick(1);//">');
	document.write('<area shape="rect" coords="75,0,140,78" href="javascript:calculateEmissionsElec_onclick(3);//">');
	document.write('<area shape="rect" coords="140,0,220,39" href="javascript:calculateEmissionsElec_onclick(4);//">');
	document.write('<area shape="rect" coords="140,39,220,78" href="javascript:calculateEmissionsElec_onclick(5);//">');
	document.write('<area shape="rect" coords="220,0,300,39" href="javascript:calculateEmissionsElec_onclick(6);//">');
	document.write('<area shape="rect" coords="220,39,300,78" href="javascript:calculateEmissionsElec_onclick(7);//">');
	document.write('<area shape="rect" coords="300,0,380,39" href="javascript:calculateEmissionsElec_onclick(8);//">');
	document.write('<area shape="rect" coords="300,39,380,78" href="javascript:calculateEmissionsElec_onclick(9);//">');
	document.write('<area shape="rect" coords="380,0,460,39" href="javascript:calculateEmissionsElec_onclick(10);//">');
	document.write('<area shape="rect" coords="380,39,460,78" href="javascript:calculateEmissionsElec_onclick(11);//">');
	document.write('<area shape="rect" coords="460,0,540,39" href="javascript:calculateEmissionsElec_onclick(12);//">');
	document.write('<area shape="rect" coords="460,39,540,78" href="javascript:calculateEmissionsElec_onclick(13);//">');
	document.write('<area shape="rect" coords="540,0,620,39" href="javascript:calculateEmissionsElec_onclick(14);//">');
	document.write('<area shape="rect" coords="540,39,620,78" href="javascript:calculateEmissionsElec_onclick(15);//">');
	document.write('<area shape="rect" coords="620,0,700,39" href="javascript:calculateEmissionsElec_onclick(16);//">');
	document.write('<area shape="rect" coords="700,0,800,78" href="javascript:calculateEmissionsElec_onclick(2);//">');
	document.write('</map>');

	document.write('<img src="bar.png" USEMAP="#nav" border=0><br><br>');

	//document.write('<p><input TYPE="reset" VALUE="Reset" NAME="reset1"><input TYPE="button" VALUE="Continue" NAME=button3 onclick="gatherGeneralData_onclick()"></form>');
	/*document.write('<p>');
	document.write('<INPUT TYPE="button" VALUE="Return to Start" NAME=button3 onclick=', start_string, '>');
	document.write('<INPUT TYPE="button" VALUE="Skip to Final Results" NAME=button4 onclick=', end_string, '>');
	document.write('<INPUT TYPE="button" VALUE="General Info" NAME=button3 onclick=', general_info, '>');
	document.write('<INPUT TYPE="button" VALUE="Transportation NTW', star(1, page), '" NAME=button4 onclick=', trans_ntw, '>');
	document.write('<INPUT TYPE="button" VALUE="Transportation TW', star(2, page), '" NAME=button3 onclick=', trans_tw, '>');
	document.write('<INPUT TYPE="button" VALUE="Office Elec NTW', star(3, page), '" NAME=button4 onclick=', elec_off_ntw, '>');
	document.write('<INPUT TYPE="button" VALUE="Office Elec TW', star(4, page), '" NAME=button3 onclick=', elec_off_tw, '>');
	document.write('<INPUT TYPE="button" VALUE="Home Elec NTW', star(5, page), '" NAME=button4 onclick=', elec_home_ntw, '>');
	document.write('<INPUT TYPE="button" VALUE="Home Elec TW', star(6, page), '" NAME=button3 onclick=', elec_home_tw, '>');
	document.write('<INPUT TYPE="button" VALUE="Office Light NTW', star(7, page), '" NAME=button4 onclick=', light_off_ntw, '>');
	document.write('<INPUT TYPE="button" VALUE="Office Light TW', star(8, page), '" NAME=button3 onclick=', light_off_tw, '>');
	document.write('<INPUT TYPE="button" VALUE="Home Light NTW', star(9, page), '" NAME=button4 onclick=', light_home_ntw, '>');
	document.write('<INPUT TYPE="button" VALUE="Home Light TW', star(10, page), '" NAME=button3 onclick=', light_home_tw, '>');
	document.write('<INPUT TYPE="button" VALUE="Office Heat NTW', star(11, page), '" NAME=button4 onclick=', heat_off_ntw, '>');
	document.write('<INPUT TYPE="button" VALUE="Office Heat TW', star(12, page), '" NAME=button3 onclick=', heat_off_tw, '>');
	document.write('<INPUT TYPE="button" VALUE="Home Heat NTW', star(13, page), '" NAME=button4 onclick=', heat_home_ntw, '>');*/
}

function help( h, winHeight )
{
	var helpstr = "help.htm?h=" + h;
	var openstr;

	if( winHeight )
	{
		winHeight = winHeight * 1.1;
		openstr = "width=400, height=" + winHeight + ", directories=0, toolbar=0, location=0, menubar=0, scrollbars=1";
	}
	else
	{
		openstr = "width=400, height=330, directories=0, toolbar=0, location=0, menubar=0, scrollbars=1";
	}

	helpWindow = window.open(helpstr,"",openstr);
	helpWindow.focus();
	return false;
}