var NS4 = (navigator.appName.indexOf("Netscape")>=0 && !document.getElementById)? true : false;
var IE4 = (document.all && !document.getElementById)? true : false;
var IE5 = (document.getElementById && document.all)? true : false;
var NS6 = (document.getElementById && navigator.appName.indexOf("Netscape")>=0 )? true: false;
var W3C = (document.getElementById)? true : false;

//create link line object
function linkline (display,lnk,lbl,ttl) {
	this.length=5;
	this.disp = display;
	this.link = lnk;
	this.label = lbl;
	this.title = ttl;
}
//array of links
var line = new Array(7);
line[0]=7;
line[1]= new linkline(true,"JLG-home.htm","Home","");
line[2]= new linkline(true,"JLG-profile.htm","Profile","Firm Profile");
line[3]= new linkline(true,"JLG-services.htm","Services","Scope of Services & Beginning the Process");
line[4]= new linkline(true,"JLG-projects.htm","Projects","Representative Projects");
line[5]= new linkline(true,"JLG-pres.htm","3D Presentations","3D Presentations");
line[6]= new linkline(true,"JLG-contact.htm","Contact","Contact Information");

//Get matching title, page index and next page
var pagetitle="";
var pageimage="";
var pageindex=1;
var nextindex=1;
for (i=1;i<line[0];i++){
	if (self.location.href.indexOf(line[i]["link"])!=-1){
		pagetitle=line[i]["title"];
		pageimage=line[i]["img"];
		pageindex=i;		
		for (j=1;i+j<line[0];j++){
			if(line[i+j]["disp"]){				
				nextindex=i+j;
				break;
			}
		}
	}
}

//build link table
function LinkTable(){
	var pagestr='<table class="menu" align="center"><tr>';
	for (i=1;i<line[0];i++){
		if (line[i]["disp"]){
			if (line[i]["title"]==pagetitle) {			
				pagestr += '<td class="menuactive" style="margin:12px;">';
				pagestr += line[i]["label"] + '</td>';
			}else{
				pagestr += '<td style="margin-bottom:6px;">';
				pagestr += '<a href="' + line[i]["link"] + '" ';
				pagestr += 'class="menuoff" style="margin:12px;"';
				pagestr += 'onMouseOver="this.className=\'menuon\';" ';
				pagestr += 'onMouseOut="this.className=\'menuoff\';">';
				pagestr += line[i]["label"] + '</a></td>';
			}
		}
	}
	pagestr += '</tr></table>';
	document.write(pagestr);
}

function LinkTableProj(){
	var pagestr='<table class="menu" align="center"><tr>';
	for (i=1;i<line[0];i++){
		if (line[i]["disp"]){
			pagestr += '<td style="margin-bottom:6px;">';
			pagestr += '<a href="' + line[i]["link"] + '" ';
			pagestr += 'class="menuoff" style="margin:12px;"';
			pagestr += 'onMouseOver="this.className=\'menuon\';" ';
			pagestr += 'onMouseOut="this.className=\'menuoff\';">';
			pagestr += line[i]["label"] + '</a></td>';
		}
	}
	pagestr += '</tr></table>';
	document.write(pagestr);
}
