menu1 = new Array(
"Los Angeles >","#","_top",
"Malibu","malibu.asp","_top",
"Orange County","orangecounty.asp","_top",
"San Diego","sandiego.asp","_top",
"Santa Barbara","santabarbara.asp","_top",
"Temecula","temecula.asp","_top",
"Las Vegas","lasvegas.asp","_top",
"Mexico","mexico.asp","_top",
"Idaho","idaho.asp","_top",
"Architectural","architectural.asp","_top",
"Equestrian","equestrian.asp","_top",
"Land & Lots","land.asp","_top",
"Rentals","rentals.asp","_top",
"Commercial","commercial.asp","_top"
);

menu2 = new Array(
"Art Galleries","galleries.asp","_top",
"Architects","architects.asp","_top",
"Interior Designers","interior.asp","_top",
"Resorts & Hotels","resorts.asp","_top",
"Polo Vacations","polo.asp","_top",
"Golf Resorts","golf.asp","_top",
"Private Villas for Rent","villas.asp","_top",
"Staging Companies","stagingco.asp","_top",
"Location Companies","locationco.asp","_top"
);

menu3 = new Array(
"Distribution Info","demographics.asp","_top",
"Publishing Portfolio","publishing.asp","_top",
"Regional Package","regional.asp","_top",
"Testimonies","testimonials.asp","_top",
"Photography","photography.asp","_top",
"Custom Brochures","print.asp","_top",
"Slideshows and DVDs","slideshowdvd.asp","_top",
"Subscriptions","subscription.asp","_top",
"Ad Submission Info","ad_submissions.asp","_top",
"Links","links.asp","_top"
);

menu4 = new Array(
"Private Air Charters","air.asp","_top",
"Limousine Services","limo.asp","_top",
"Valet Services","valets.asp","_top",
"Sportfishing Tours","sportfishing.asp","_top",
"Exotic Surf Excursions","surf.asp","_top"
);

menu5 = new Array(
"West Side","losangeles_west_side.asp","_top",
"South Bay","losangeles_south_bay.asp","_top",
"Coastal Cities","losangeles_coastal_cities.asp","_top"
);

function makeMenu(menu) { 
	num_items = eval(menu + ".length");
	ns = (navigator.appName == "Netscape") ? true : false;
	menu_table = (ns) ? "<table cellspacing=0 cellpadding=0 border=0>" : "<table cellspacing=0 cellpadding=3 border=0>";
	z = 0;
	if (ns) {
		for (x = 0; x < num_items; x += 3) { 
			special = (menu == "menu1") ? "; show_submenu(" + z + ");" : "";
			z++;
			if (z > 1) menu_table += "<tr><td height=1 bgcolor=#999999></td></tr>";
			menu_table += "<tr height=22 bgColor='#ffcc99' onMouseOver=\"this.bgColor='#CCCCCC'" + special + "\" " +
			"onMouseOut=\"this.bgColor='#ffcc99'\">" +
			"<td name=row" + z + " style=\"cursor: hand; color: #003366; font-family: arial; font-size: 10pt\" " +
			"onMouseover=\"this.style.color='#003366'\" " +
			"onMouseout=\"this.style.color='#003366'\">&nbsp;" +
			"<a href=\"" + eval(menu + '[x+1]') + "\" target=\"" + eval(menu + '[x+2]') + "\" style=\"color:#003366;text-decoration:none;font-weight:normal\" " +
			"onMouseover=\"this.style.color='#003366'\" " +
			"onMouseout=\"this.style.color='#003366'\">" +
			eval(menu + '[x]') + "&nbsp;&nbsp;&nbsp;</a></td></tr>";
		}
	} else {
		for (x = 0; x < num_items; x += 3) { 
			special = (menu == "menu1") ? "; show_submenu(" + z + ");" : "";
			z++;
			if (z > 1) menu_table += "<tr><td height=1 bgcolor=#999999></td></tr>";
			menu_table += "<tr height=22 bgColor='#ffcc99' onMouseOver=\"this.bgColor='#CCCCCC'" + special + "\" " +
			"onMouseOut=\"this.bgColor='#ffcc99'\">" +
			"<a href=\"" + eval(menu + '[x+1]') + "\" target=\"" + eval(menu + '[x+2]') + "\">" +
			"<td name=row" + z + " style=\"cursor: hand; color: #003366; font-family: arial; font-size: 10pt\" " +
			"onMouseover=\"this.style.color='#003366'\" " +
			"onMouseout=\"this.style.color='#003366'\">&nbsp;" +
			eval(menu + '[x]') + "&nbsp;&nbsp;</td></a></tr>";
		}
	}
	menu_table += "<tr><td height=1 bgcolor=#999999></td></tr></table>";
	document.write(menu_table);
}

function makeMenu1(menu) { 
	num_items = eval(menu + ".length");
	ns = (navigator.appName == "Netscape") ? true : false;
	menu_table = (ns) ? "<table cellspacing=0 cellpadding=0 border=0>" : "<table cellspacing=0 cellpadding=3 border=0>";
	z = 0;
	if (ns) {
		for (x = 0; x < num_items; x += 3) { 
			z++;
			special = "; hide1('menu5_div')";
			if (x == 0) special = "; show1('menu5_div')"; 
			if (z > 1) menu_table += "<tr><td height=1 bgcolor=#999999></td></tr>";
			menu_table += "<tr height=22 bgColor='#ffcc99' onMouseOver=\"this.bgColor='#CCCCCC'" + special + "\" " +
			"onMouseOut=\"this.bgColor='#ffcc99'\">" +
			"<td name=row" + z + " style=\"cursor: hand; color: #003366; font-family: arial; font-size: 10pt\" " +
			"onMouseover=\"this.style.color='#003366'\" " +
			"onMouseout=\"this.style.color='#003366'\">&nbsp;" +
			"<a href=\"" + eval(menu + '[x+1]') + "\" target=\"" + eval(menu + '[x+2]') + "\" style=\"color:#003366;text-decoration:none;font-weight:normal\" " +
			"onMouseover=\"this.style.color='#003366'\" " +
			"onMouseout=\"this.style.color='#003366'\">" +
			eval(menu + '[x]') + "&nbsp;&nbsp;&nbsp;</a></td></tr>";
		}
	} else {
		for (x = 0; x < num_items; x += 3) { 
			z++;
			special = "; hide1('menu5_div')";
			if (x == 0) special = "; show1('menu5_div')"; 
			if (z > 1) menu_table += "<tr><td height=1 bgcolor=#999999></td></tr>";
			menu_table += "<tr height=22 bgColor='#ffcc99' onMouseOver=\"this.bgColor='#CCCCCC'" + special + "\" " +
			"onMouseOut=\"this.bgColor='#ffcc99'\">" +
			"<a href=\"" + eval(menu + '[x+1]') + "\" target=\"" + eval(menu + '[x+2]') + "\">" +
			"<td name=row" + z + " style=\"cursor: hand; color: #003366; font-family: arial; font-size: 10pt\" " +
			"onMouseover=\"this.style.color='#003366'\" " +
			"onMouseout=\"this.style.color='#003366'\">&nbsp;" +
			eval(menu + '[x]') + "&nbsp;&nbsp;</td></a></tr>";
		}
	}
	menu_table += "<tr><td height=1 bgcolor=#999999></td></tr></table>";
	document.write(menu_table);
}

function makeMenu5(menu) { 
	num_items = eval(menu + ".length");
	ns = (navigator.appName == "Netscape") ? true : false;
	menu_table = (ns) ? "<table cellspacing=0 cellpadding=0 border=0>" : "<table cellspacing=0 cellpadding=3 border=0>";
	z = 0;
	if (ns) {
		for (x = 0; x < num_items; x += 3) { 
			z++;
			if (z > 1) menu_table += "<tr><td height=1 bgcolor=#999999></td></tr>";
			menu_table += "<tr height=22 bgColor='#006699' onMouseOver=\"this.bgColor='#CCCCCC'" + special + "\" " +
			"onMouseOut=\"this.bgColor='#006699'\">" +
			"<td name=row" + z + " style=\"cursor: hand; color: #FFFFFF; font-family: arial; font-size: 10pt\" " +
			"onMouseover=\"this.style.color='#006699'\" " +
			"onMouseout=\"this.style.color='#FFFFFF'\">&nbsp;" +
			"<a href=\"" + eval(menu + '[x+1]') + "\" target=\"" + eval(menu + '[x+2]') + "\" style=\"color:#FFFFFF;text-decoration:none;font-weight:normal\" " +
			"onMouseover=\"this.style.color='#006699'\" " +
			"onMouseout=\"this.style.color='#FFFFFF'\">" +
			eval(menu + '[x]') + "&nbsp;&nbsp;&nbsp;</a></td></tr>";
		}
	} else {
		for (x = 0; x < num_items; x += 3) { 
			z++;
			if (z > 1) menu_table += "<tr><td height=1 bgcolor=#999999></td></tr>";
			menu_table += "<tr height=22 bgColor='#006699' onMouseOver=\"this.bgColor='#CCCCCC'" + special + "\" " +
			"onMouseOut=\"this.bgColor='#006699'\">" +
			"<a href=\"" + eval(menu + '[x+1]') + "\" target=\"" + eval(menu + '[x+2]') + "\">" +
			"<td name=row" + z + " style=\"cursor: hand; color: #FFFFFF; font-family: arial; font-size: 10pt\" " +
			"onMouseover=\"this.style.color='#006699'\" " +
			"onMouseout=\"this.style.color='#FFFFFF'\">&nbsp;" +
			eval(menu + '[x]') + "&nbsp;&nbsp;</td></a></tr>";
		}
	}
	menu_table += "</table>";
	document.write(menu_table);
}

function show1(menu) { 
	document.getElementById(menu).style.visibility = 'visible';
}

function hide1(menu) { 
	document.getElementById(menu).style.visibility = 'hidden';
}

function show(menu) { 
	hideAll();
	for (x = 1; x <= 5; x++) { 
		eval("document.getElementById('menu" + x + "_div').style.visibility = 'hidden'")
	}
	document.getElementById(menu).style.visibility = 'visible';
}

function hideAll() { 
	for (x = 1; x <= 5; x++) { 
		eval("document.getElementById('menu" + x + "_div').style.visibility = 'hidden'")
	}
}

function trim(str) {
	var whitespace = new String(" \t\n\r");
	var s = new String(" " + str + " ");
	if (whitespace.indexOf(s.charAt(0)) != -1) {
		var j=0, i = s.length;
            while (j < i && whitespace.indexOf(s.charAt(j)) != -1) {
			j++;
		}
            s = s.substring(j, i);
	}

	if (whitespace.indexOf(s.charAt(s.length-1)) != -1) {
		var i = s.length - 1;       
            while (i >= 0 && whitespace.indexOf(s.charAt(i)) != -1) {
			i--;
		}
            s = s.substring(0, i+1);
	}
	return s;
}
