menu0on = new Image();menu0on.src = "images/menu_home_on.jpg";menu0off = new Image();menu0off.src = "images/menu_home_off.jpg";menu1on = new Image();menu1on.src = "images/menu_gallery_on.jpg";menu1off = new Image();menu1off.src = "images/menu_gallery_off.jpg";menu2on = new Image();menu2on.src = "images/menu_stock_on.jpg";menu2off = new Image();menu2off.src = "images/menu_stock_off.jpg";menu_active2on = new Image();menu_active2on.src = "images/menu_stock_active_on.jpg";menu_active2off = new Image();menu_active2off.src = "images/menu_stock_active_off.jpg";menu3on = new Image();menu3on.src = "images/menu_about_on.jpg";menu3off = new Image();menu3off.src = "images/menu_about_off.jpg";menu4on = new Image();menu4on.src = "images/menu_contact_on.jpg";menu4off = new Image();menu4off.src = "images/menu_contact_off.jpg";function calculateSumOffset(idItem, offsetName) {	var totalOffset = 0;	var item = eval('idItem');	do {		totalOffset += eval('item.'+offsetName);		item = eval('item.offsetParent');	}	while (item != null);	return totalOffset;}function openIt(x) {	var items = 4	var menu;	var submenu;	for (i=0; i<=items; i++) {if (document.getElementById) {	eval("document.getElementById(\"box" + i + "\").style.visibility = \"hidden\"");	eval("document.getElementById(\"box" + x + "\").style.visibility = \"visible\"");	eval("document.getElementById(\"box" + x + "\").style.top=105");	menu = eval("document.images[\"menu" + x + "\"]");	submenu = eval("document.getElementById(\"box" + x + "\").style");	submenu.left = calculateSumOffset(menu, 'offsetLeft') + 6;	submenu.top  = calculateSumOffset(menu, 'offsetTop') + 32;	}else if (document.layers) {	document.layers[i].visibility = "hide"	document.layers[x].visibility = "show"	document.layers[x].left=document.layers[x].pageX;	document.layers[x].top=document.layers[x].pageY;	}else if (document.all) {	eval("document.all.box" + i + ".style.visibility = \"hidden\"");	eval("document.all.box" + x + ".style.visibility = \"visible\"");	eval("document.all.box" + x + ".style.top=105");	menu = eval("document.images[\"menu" + x + "\"]");	submenu = eval("document.all.box" + x + ".style");	submenu.left = calculateSumOffset(menu, 'offsetLeft') + 6;	submenu.top  = calculateSumOffset(menu, 'offsetTop') + 32;	}}}function closeIt() {	var items = 5	for (i=0; i<items; i++) {if (document.getElementById) {eval("document.getElementById(\"box" + i + "\").style.visibility = \"hidden\"");}else if(document.layers){document.layers[i].visibility = "hide"}else if (document.all){eval("document.all.box" + i + ".style.visibility = \"hidden\"");}document.images["menu2"].src = menu2off.src; }}var mouseOverMenu = falsevar timeIDfunction mouseOverLayer() {	mouseOverMenu = true;}function mouseOutLayer() {	mouseOverMenu = false;}function timeIt() {	if(!mouseOverMenu) {	timeID = setTimeout("closeIt()",500)	}}function clearIt() {	if(mouseOverMenu) {	clearTimeout(timeID)	}}// CSS Menu code abovefunction replaceChars(entry) {	temp = entry.split("'")	mytemp = temp[0]	for (i=1; i<temp.length; i++) {		mytemp = mytemp + temp[i]	}	return mytemp;}function searchCheck(form) {	if ((form.photo_num.value == "") && (form.model_release.checked == 0)) {		if ((form.category.selectedIndex == 0) && (form.keyword.selectedIndex == 0)) {		alert("You must select a category and/or keyword before you can continue.");		return false;		}	}}function forgotCheck(form) {	if (form.email.value == "") {		alert("You must enter the email address used for login before you can continue.");		return false;	}}function boxChange() {	var x = "change"	var y = eval("document.ChangeLightbox.box_id["+document.forms.ChangeLightbox.box_id.selectedIndex+"].value");	var z = eval("document.ChangeLightbox.currentboxpage.value")	eval("document.location.href='results2.asp?action=" + x + "&box_id=" + y + "&currentboxpage=" + z + "';");}function boxChange2() {	var x = "change"	var y = eval("document.ChangeLightbox.box_id["+document.forms.ChangeLightbox.box_id.selectedIndex+"].value");	var z = eval("document.ChangeLightbox.currentboxpage.value")	eval("document.location.href='lightbox2.asp?action=" + x + "&box_id=" + y + "&currentboxpage=" + z + "';");}function boxCheck(x,y,z) {	var w	if (x == 'new') {		if (w = prompt('Please enter a name for your lightbox:','My Untitled Lightbox')) {			eval("document.location.href='results2.asp?action=" + x + "&photo_id=" + y + "&currentpage=" + z + "&boxname=" + replaceChars(w) + "';");		}	}	if (x == 'add') {		eval("document.location.href='results2.asp?action=" + x + "&photo_id=" + y + "&currentpage=" + z + "';");	}}function boxControl() {	var w	var x = eval("document.ChangeLightbox.action["+document.forms.ChangeLightbox.action.selectedIndex+"].value");	var y = eval("document.ChangeLightbox.box_id["+document.forms.ChangeLightbox.box_id.selectedIndex+"].value");	var z = eval("document.ChangeLightbox.currentboxpage.value")	if (y == '') {		alert("Please select a Lightbox Name before selecting your Lightbox Options.");		document.forms.ChangeLightbox.action.selectedIndex = 0		document.forms.ChangeLightbox.box_id.focus();	} else {		if (x == 'view') {			eval("document.location.href='results2.asp?action=" + x + "&box_id=" + y + "&currentboxpage=" + z + "';");		}		if (x == 'describe') {			if (w = prompt('Please enter a short description for this lightbox:','My short lightbox description here.')) {				eval("document.location.href='results2.asp?action=" + x + "&box_id=" + y + "&currentboxpage=" + z + "&boxname=" + replaceChars(w) + "';");			}		}		if (x == 'create') {			if (w = prompt('Please enter a name for your lightbox:','My Untitled Lightbox')) {				if (w.length > 20) {					alert("Please keep your Lightbox Name to less than 20 characters.");				} else {					eval("document.location.href='results2.asp?action=" + x + "&currentboxpage=" + z + "&boxname=" + replaceChars(w) + "';");				}			}		}		if (x == 'email') {			if (w = prompt('Please enter a properly formated email address to send this lightbox to:','yourname@yourdomain.com')) {				eval("document.location.href='results2.asp?action=" + x + "&box_id=" + y + "&currentboxpage=" + z + "&boxname=" + w + "';");			}		}		if (x == 'rename') {			if (w = prompt('Please enter a your new name for your lightbox:','My New Lightbox')) {				eval("document.location.href='results2.asp?action=" + x + "&box_id=" + y + "&currentboxpage=" + z + "&boxname=" + replaceChars(w) + "';");			}		}		if (x == 'delete') {			if (confirm("Are you sure that you would like to delete your lightbox?")) {			eval("document.location.href='results2.asp?action=" + x + "&box_id=" + y + "&currentboxpage=" + z + "';");			}			else {			return false;			}		}	}}function boxControl2(x,y,z) {	var w	var y	if (x == 'view') {		eval("document.location.href='lightbox2.asp?action=" + x + "&box_id=" + y + "&currentpage=" + z + "';");	}	if (x == 'create') {		if (w = prompt('Please enter a name for your lightbox:','My Untitled Lightbox')) {			if (w.length > 20) {				alert("Please keep your Lightbox Name to less than 20 characters.");			} else {				eval("document.location.href='lightbox2.asp?action=" + x + "&currentpage=" + z + "&boxname=" + replaceChars(w) + "';");			}		}	}	if (x == 'email') {		if (w = prompt('Please enter a properly formated email address to send this lightbox to:','yourname@yourdomain.com')) {			eval("document.location.href='lightbox2.asp?action=" + x + "&box_id=" + y + "&currentpage=" + z + "&boxname=" + w + "';");		}	}	if (x == 'rename') {		if (w = prompt('Please enter a your new name for your lightbox:','My New Lightbox')) {			eval("document.location.href='lightbox2.asp?action=" + x + "&box_id=" + y + "&currentpage=" + z + "&boxname=" + replaceChars(w) + "';");		}	}	if (x == 'delete') {		if (confirm("Are you sure that you would like to delete your lightbox?")) {		eval("document.location.href='lightbox2.asp?action=" + x + "&box_id=" + y + "&currentpage=" + z + "';");		}		else {		return false;		}	}}