function showBlock(what) {
	document.getElementById(what).style.display = 'block';
}

function showInline(what) {
	document.getElementById(what).style.display = 'inline';
}

function hide(what) {
	document.getElementById(what).style.display = 'none';
}

function toggleBlock(what) {
	if (document.getElementById(what).style.display == 'none') {
		showBlock(what);
	}
	else {
		hide(what);
	}
}
function toggleInline(what) {
	if (document.getElementById(what).style.display == 'none') {
		showInline(what);
	}
	else {
		hide(what);
	}
}

function showLightbox(id) {
	if (/MSIE (\d+\.\d+);/.test(navigator.userAgent)) {
		var ieversion = new Number(RegExp.$1);
		if ((ieversion >= 6) || (ieversion >= 5)) {
			window.scrollTo(0,0);
		}
	}
	showBlock('overlay');
	showBlock(id);
}

function hideLightbox(id) {
	hide('overlay');
	hide(id);
}

function togglePanels(what) {
	var switchVariable;
	
	if(what == "departmentStoresPanel") {
		switchVariable = 1;
	} else if (what == "militaryPanel") {
		switchVariable = 2;		
	} else if (what == "collegiatePanel") {
		switchVariable = 3;
	} else if (what == "sportingGoodsPanel") {
		switchVariable = 4;
	}
	
	switch(switchVariable) {
		case 1: 
			toggleBlock('departmentStoresPanel');
			hide('militaryPanel');
			hide('collegiatePanel');
			hide('sportingGoodsPanel');
			break;
		case 2: 
			toggleBlock('militaryPanel');
			hide('departmentStoresPanel');
			hide('collegiatePanel');
			hide('sportingGoodsPanel');
			break;
		case 3: 
			toggleBlock('collegiatePanel');
			hide('departmentStoresPanel');
			hide('militaryPanel');
			hide('sportingGoodsPanel');
			break;
		case 4: 
			toggleBlock('sportingGoodsPanel');
			hide('departmentStoresPanel');
			hide('militaryPanel');
			hide('collegiatePanel');
			break;
		default: break;
	}
}