var linkarray=new Array();
linkarray[0]="http://www.bikenewyork.org/rides/hvrr/index.html";
linkarray[1]="http://www.bikenewyork.org/rides/hvrr/register.html";
linkarray[2]="";
linkarray[3]="http://www.bikenewyork.org/rides/hvrr/event_info.html";
linkarray[4]="http://www.bikenewyork.org/rides/hvrr/getting_there.html";
linkarray[5]="http://www.bikenewyork.org/rides/hvrr/lodging.html";
linkarray[6]="http://www.bikenewyork.org/rides/hvrr/sat_activities.html";
linkarray[7]="http://www.bikenewyork.org/rides/hvrr/about_hv.html";
linkarray[8]="http://www.bikenewyork.org/rides/hvrr/get_ready.html";
linkarray[9]="";
linkarray[10]="http://www.bikenewyork.org/rides/hvrr/photo_gallery_2009.html";
linkarray[11]="http://www.bikenewyork.org/rides/hvrr/photo_gallery_2008.html";
linkarray[12]="http://www.bikenewyork.org/rides/hvrr/photo_gallery_2007.html";
linkarray[13]="http://www.bikenewyork.org/rides/hvrr/sponsors_partners.html";
linkarray[14]="http://www.bikenewyork.org/rides/hvrr/volunteer.html";


var structure=new Array();
	structure[0]="main";
	structure[1]="main";
	structure[2]="main";
	structure[3]="sub";
	structure[4]="sub";
	structure[5]="sub";
	structure[6]="sub";
	structure[7]="sub";
	structure[8]="main";
	structure[9]="main";
	structure[10]="sub";
	structure[11]="sub";
	structure[12]="sub";
	structure[13]="main";
	structure[14]="main";
	

var linktext=new Array();
	linktext[0]="Home";
	linktext[1]="Register";
	linktext[2]="Practical Info";
	linktext[3]="\-Event Info";
	linktext[4]="\-Getting There";
	linktext[5]="\-Lodging";
	linktext[6]="\-Saturday Activities";
	linktext[7]="\-About the Harlem Valley";
	linktext[8]="Get Ready";
	linktext[9]="Photos";
	linktext[10]="\-2009";
	linktext[11]="\-2008";
	linktext[12]="\-2007";
	linktext[13]="Sponsors and Partners";
	linktext[14]="Volunteer";



function getCurrentPage() {
	var page=document.URL;
	for(i=0;i<linkarray.length;i++) {
		if (linkarray[i]==document.URL) {
			//alert("match");	
			return i;
		}	
	}
}
function makenav(){
	var str='';
	str+='<table cellpadding="4" cellspacing="1" class="menu" width="100" border="0">';
	for(j=0;j<linkarray.length;j++) {
		str+='<tr>';
		if(getCurrentPage()==j) {
			str+='<td width="100" class="leftnav_box_selected"><span class="leftnav_' + structure[j] + '_selected">' + linktext[j] + '<\/span><\/td>';
		 } else if ((linktext[j]=="Practical Info") || (linktext[j]=="Photos")) {
				//not a link- use blueheadline style
				str+='<td class="leftnav_' + structure[j] + '"><span class="nolink">' + linktext[j] + '<\/span><\/td>';
		}else {
			str+='<td width ="100" class="leftnav_' + structure[j] + '"><a class="leftnav_' + structure[j] + '" href="' + linkarray[j] + '">' + linktext[j] + '<\/a><\/td>';
		}	
		str+='<\/tr>';
	}
	
	str+='<tr><td>&nbsp;</td></tr>';
	str+='<tr><td>&nbsp;</td></tr>';
	str+='<tr><td>&nbsp;</td></tr>';	
	str+='<tr><td>&nbsp;</td></tr>';
	str+='<tr><td>&nbsp;</td></tr>';	
	
	str+='<\/table>';
	document.write(str);
}
//getCurrentPage();
//writeJS();
makenav();