/************************************************
*                                               *
*	For use with riverbanks.org                 *
*                                               *
*	written by Michael Rathmann                 *
*	(c)RathmannDesign.com. All rights reserved. *
*                                               *
************************************************/

// QUICK FIND MENU
function mmLoadMenus() {
	if (window.mm_quickNav) return;
	nosecureUrl = 'http://www.riverbanks.org';
	secureUrl = 'https://www.riverbanks.org';

window.mm_quickNav = new Menu("root",160,16,"Arial,Helvetica,sans-serif",10,"#ffffff","#000000","#993300","#DCCEA7","left","middle",3,0,1000,-5,7,true,false,true,0,false,false);
	mm_quickNav.addMenuItem("&raquo; Admission Rates","location=nosecureUrl+'/planvisit/visitorinfo.shtml#rates'");
	mm_quickNav.addMenuItem("&raquo; Contact Information","location=nosecureUrl+'/contactus.shtml'");
	mm_quickNav.addMenuItem("&raquo; Demonstration Times","location=nosecureUrl+'/planvisit/visitorinfo.shtml#demos'");
	mm_quickNav.addMenuItem("&raquo; Directions/Map(s)","location=nosecureUrl+'/planvisit/visitorinfo.shtml#directions'");
	mm_quickNav.addMenuItem("&raquo; Group Information","location=nosecureUrl+'/planvisit/groupvisits.shtml'");
	mm_quickNav.addMenuItem("&raquo; Hours of Operation","location=nosecureUrl+'/planvisit/visitorinfo.shtml#hours'");
	mm_quickNav.addMenuItem("&raquo; Job Openings","location=nosecureUrl+'/jointeam/joblisting.shtml'");
	mm_quickNav.addMenuItem("&raquo; Local Hotels","location=nosecureUrl+'/planvisit/visitorinfo.shtml#hotel'");
	mm_quickNav.addMenuItem("&raquo; Make a Contribution","location=nosecureUrl+'/donate/'");
	mm_quickNav.addMenuItem("&raquo; Membership Info","location=nosecureUrl+'/membership/'");
	mm_quickNav.addMenuItem("&raquo; Plan a Company Event","location=nosecureUrl+'/corpevents/'");
	mm_quickNav.addMenuItem("&raquo; Corporate Membership Club","location=nosecureUrl+'/corpevents/tickets.shtml'");
	mm_quickNav.addMenuItem("&raquo; Plan Your Wedding","location=nosecureUrl+'/romance/'");
	mm_quickNav.addMenuItem("&raquo; Print Zoo Brochure*","pdfWindow2('/assets/pdf/zoobrochure.pdf',800,500)");
	mm_quickNav.addMenuItem("&raquo; Related Links","location=nosecureUrl+'/relatedlinks.shtml'");
	mm_quickNav.addMenuItem("*requires Adobe Reader*","eticketsWindow2('http://www.adobe.com/products/acrobat/readstep2.html',800,500)");
	mm_quickNav.fontWeight="bold";
	mm_quickNav.hideOnMouseOut=true;
	mm_quickNav.bgColor='#ffffcc';
	
	mm_quickNav.writeMenus();
}


// ROLLOVER EFFECTS
var loaded = new Array();
function F_loadRollover(image,imageName) {
	if (image && image.src &&
		(null == image.out || typeof(image.out) == typeof(void(0)))) {
		s = image.src;
		image.out = new Image();
		image.out.src = s;
		image.over = new Image();
		if (imageName.lastIndexOf('/') >= 0 || imageName.lastIndexOf('\\') >= 0) {
			s = imageName;
		} else {
			i = s.lastIndexOf('/');
			if (i<0) i = s.lastIndexOf('\\');
			if (i<0) { s = imageName; }
			else	 { s = s.substring(0,i+1) + imageName; }
		}
		image.over.src = s;
		loaded[image.name] = image;
	}
} function F_roll(imageName,over) {
	if (document.images) {
	if (over) { imageObject = "over"; }
	else	  { imageObject = "out"; }
	image = loaded[imageName];
	if (image) {
		ref = eval("image."+imageObject);
		if (ref) image.src = eval("image."+imageObject+".src");
	}
	if (window.event)
		window.event.cancelBubble = true;
	}
}


//	Browser Check Variables
var agt=navigator.userAgent.toLowerCase();
var is_major = parseInt(navigator.appVersion);
var is_minor = parseFloat(navigator.appVersion);

var is_nav  = ((agt.indexOf('mozilla')!=-1) && (agt.indexOf('spoofer')==-1)
	&& (agt.indexOf('compatible') == -1) && (agt.indexOf('opera')==-1)
	&& (agt.indexOf('webtv')==-1) && (agt.indexOf('hotjava')==-1));
var is_nav4up = (is_nav && (is_major >= 4));
var is_nav6up = (is_nav && (is_major >= 5));

var is_ie     = ((agt.indexOf("msie") != -1) && (agt.indexOf("opera") == -1));
var is_ie3    = (is_ie && (is_major < 4));
var is_ie4    = (is_ie && (is_major == 4) && (agt.indexOf("msie 4")!=-1) );
var is_ie5up  = (is_ie && !is_ie3 && !is_ie4);


// FORM EFFECTS
function handleFocus(form) { form.id = "fieldon"; }
function handleBlur(form) { form.id = "fieldoff"; }
function formFocus(form) { form.id = "fieldon_form"; }
function formBlur(form) { form.id = "fieldoff_form"; }


// POP-UP WINDOWS
var chasm = screen.availWidth; var mount = screen.availHeight;
var width = 0; var height = 0;
var aux = null; var aux2 = null;
function eticketsWindow(width,height) {
	if (aux2 != null && aux2.open) aux2.close();
	aux2 = window.open('','etickets','resizable=yes,location=yes,toolbar=yes,scrollbars=yes,status=yes,width=' + width + ',height=' + height + ',left=' + ((chasm - width - 10) * .5) + ',top=' + ((mount - height - 30) * .5));
} function eticketsWindow2(url,width,height) {
	if (aux2 != null && aux2.open) aux2.close();
	aux2 = window.open(url,'etickets','resizable=yes,location=yes,toolbar=yes,scrollbars=yes,status=yes,width=' + width + ',height=' + height + ',left=' + ((chasm - width - 10) * .5) + ',top=' + ((mount - height - 30) * .5));
	if (!aux2) { alert("A popup blocker was detected. Please allow for popups on this Web site in order to continue."); }
} function pdfWindow(width,height) {
	if (aux != null && aux.open) aux.close();
	aux = window.open('','pdf','resizable=yes,toolbar=no,scrollbars=yes,status=yes,width=' + width + ',height=' + height + ',left=' + ((chasm - width - 10) * .5) + ',top=' + ((mount - height - 30) * .5));
} function pdfWindow2(url,width,height) {
	if (aux != null && aux.open) aux.close();
	aux = window.open(url,'pdf','resizable=yes,toolbar=no,scrollbars=yes,status=yes,width=' + width + ',height=' + height + ',left=' + ((chasm - width - 10) * .5) + ',top=' + ((mount - height - 30) * .5));
	if (!aux) { alert("A popup blocker was detected. Please allow for popups on this Web site in order to continue."); }
} function popWindow(width,height) {
	if (aux != null && aux.open) aux.close();
	aux = window.open('','pop','resizable=yes,location=yes,toolbar=yes,scrollbars=yes,status=yes,width=' + width + ',height=' + height + ',left=' + ((chasm - width - 10) * .5) + ',top=' + ((mount - height - 30) * .5));
} function popWindow2(url,width,height) {
	if (aux != null && aux.open) aux.close();
	aux = window.open(url,'pop','resizable=yes,location=yes,toolbar=yes,scrollbars=yes,status=yes,width=' + width + ',height=' + height + ',left=' + ((chasm - width - 10) * .5) + ',top=' + ((mount - height - 30) * .5));
	if (!aux) { alert("A popup blocker was detected. Please allow for popups on this Web site in order to continue."); }
} function videoWindow(width,height) {
	if (aux != null && aux.open) aux.close();
	aux = window.open('','video','resizable=no,toolbar=no,scrollbars=no,status=no,width=' + width + ',height=' + height + ',left=' + ((chasm - width - 10) * .5) + ',top=' + ((mount - height - 30) * .5));
} function videoWindow2(url,width,height) {
	if (aux != null && aux.open) aux.close();
	aux = window.open(url,'video','resizable=no,toolbar=no,scrollbars=no,status=no,width=' + width + ',height=' + height + ',left=' + ((chasm - width - 10) * .5) + ',top=' + ((mount - height - 30) * .5));
	if (!aux) { alert("A popup blocker was detected. Please allow for popups on this Web site in order to continue."); }
} function mediaWindow(width,height) {
	if (aux != null && aux.open) aux.close();
	aux = window.open('','media','resizable=no,toolbar=no,scrollbars=no,status=no,width=' + width + ',height=' + height + ',left=' + ((chasm - width - 10) * .5) + ',top=' + ((mount - height - 30) * .5));
} function mediaWindow2(url,width,height) {
	if (aux != null && aux.open) aux.close();
	aux = window.open(url,'media','resizable=no,toolbar=no,scrollbars=no,status=no,width=' + width + ',height=' + height + ',left=' + ((chasm - width - 10) * .5) + ',top=' + ((mount - height - 30) * .5));
	if (!aux) { alert("A popup blocker was detected. Please allow for popups on this Web site in order to continue."); }
} function zooviewWindow(width,height) {
	if (aux != null && aux.open) aux.close();
	aux = window.open('','zooview','resizable=no,toolbar=no,scrollbars=no,status=no,width=' + width + ',height=' + height + ',left=' + ((chasm - width - 10) * .5) + ',top=' + ((mount - height - 30) * .5));
} function zooviewWindow2(url,width,height) {
	if (aux != null && aux.open) aux.close();
	aux = window.open(url,'zooview','resizable=no,toolbar=no,scrollbars=no,status=no,width=' + width + ',height=' + height + ',left=' + ((chasm - width - 10) * .5) + ',top=' + ((mount - height - 30) * .5));
	if (!aux) { alert("A popup blocker was detected. Please allow for popups on this Web site in order to continue."); }
} function eradic() {
	if (aux != null && aux.open) aux.close();
}

function openTable(tableid) {
	which = document.getElementById(tableid);
	if (which.style.display == "block") { which.style.display = "none"; }
	else { which.style.display = "block"; }
}