var home_on = new Image;
var home_of = new Image;
var cont_on = new Image;
var cont_of = new Image;
var supp_on = new Image;
var supp_of = new Image;
var abou_on = new Image;
var abou_of = new Image;
var stor_on = new Image;
var stor_of = new Image;
var witn_on = new Image;
var witn_of = new Image;
var outr_on = new Image;
var outr_of = new Image;
var reso_on = new Image;
var reso_of = new Image;


var cwd = getCwd();

	home_on.src = "http://www.thecrosscurrent.com/images/menu/home_on.gif";
	home_of.src = "http://www.thecrosscurrent.com/images/menu/home_off.gif";
	abou_on.src = "http://www.thecrosscurrent.com/images/menu/about_on.gif";
	abou_of.src = "http://www.thecrosscurrent.com/images/menu/about_off.gif";
	cont_on.src = "http://www.thecrosscurrent.com/images/menu/contact_on.gif";
	cont_of.src = "http://www.thecrosscurrent.com/images/menu/contact_off.gif";
	supp_on.src = "http://www.thecrosscurrent.com/images/menu/support_on.gif";
	supp_of.src = "http://www.thecrosscurrent.com/images/menu/support_off.gif";
	stor_on.src = "http://www.thecrosscurrent.com/images/menu/store_on.gif";
	stor_of.src = "http://www.thecrosscurrent.com/images/menu/store_off.gif";
	witn_on.src = "http://www.thecrosscurrent.com/images/menu/witnessing_on.gif";
	witn_of.src = "http://www.thecrosscurrent.com/images/menu/witnessing_off.gif";
	outr_on.src = "http://www.thecrosscurrent.com/images/menu/outreach_on.gif";
	outr_of.src = "http://www.thecrosscurrent.com/images/menu/outreach_off.gif";
	reso_on.src = "http://www.thecrosscurrent.com/images/menu/resources_on.gif";
	reso_of.src = "http://www.thecrosscurrent.com/images/menu/resources_off.gif";

function show(id) {
	var elem = document.getElementById(id+'sub');
	elem.style.display = "block";
}
function show2(id) {
	var elem = document.getElementById(id+'sub');
	elem.style.display = "block";
}
function hide(id) {
	var elem = document.getElementById(id+'sub');
	elem.style.display = "none";
}
function hide2(id) {
	var elem = document.getElementById(id+'sub');
	elem.style.display = "none";
}

function getFilename() {
	var url = getURL();
	var xstart = url.lastIndexOf("/")+1;
	var xend = url.length;
	return url.substring(xstart,xend);
}

function getCwd() {
	var url = getURL();
	var xstart = url.lastIndexOf("/")+1;
	return url.substring(0,xstart);
}

function getURL() {
	return unescape(location.href);	
}

function showCurPg() {
	if (getFilename() != "index.html") {
		document.getElementById(getFilename()).style.backgroundColor = "#FFFFFF";
	}
}