if(parseInt(navigator.appVersion) < 4) {
	document.write('<hr><h1>Sorry, a 4.0+ browser is required to view this site.</h1>');
	document.write('Your browser cannot run this site.');}

function makeNewWindow(windowURL, windowName, windowParam){ newWindow = window.open(windowURL, windowName, windowParam)}

/*var africa_selection = "'no'";
var asia_selection = "'no'";
var north_selection = "'no'";
var archaeo_selection = "'no'";
var pacific_selection = "'no'";
var central_selection = "'no'";
var south_selection = "'no'";
var bio_selection = "'no'";*/

optionsArray = new Array();
optionsArray[0] = "home";
optionsArray[1] = "coll";
optionsArray[2] = "exph";
optionsArray[3] = "hist";
// optionsArray[4] = "thes";

optionsArray[4] = "arch";
optionsArray[5] = "res";

optionsArray[6] = "asia";
optionsArray[7] = "nae";
optionsArray[8] = "pac";
optionsArray[9] = "naa";
optionsArray[10] = "caa";
optionsArray[11] = "bio";

optionsArray[12] = "sub";
optionsArray[13] = "man";
optionsArray[14] = "cons";
optionsArray[15] = "img";

optionsArray[16] = "staff";
optionsArray[17] = "access";
optionsArray[18] = "intern";
optionsArray[19] = "guest";
optionsArray[20] = "web";

img_inactive = new Image(); img_inactive.src = "/graphics/arrow_black.gif";
img_active = new Image(); img_active.src = "/graphics/arrow_red.gif";
// var img_prop = "border='0' hspace='2' vspace='0' width='7' height='7'";
var img_current = "";

function getArrayIndex(valueParam){
for ( var i = 0; i < optionsArray.length; i++ )
    if (optionsArray[i]==valueParam)
       return(i); 
return(-1); }

function setActiveLink(indexParam){
/*    document.links[indexParam].style.color="#B30000";
    document.links[indexParam].style.textDecoration="none";
    document.links[indexParam].style.backgroundColor="#F5F5F5";
    document.links[indexParam].style.backgroundColor="#DEDEDE";
    document.links[indexParam].style.fontWeight="normal";*/
    document.links[indexParam].style.color="#B30000";
    document.links[indexParam].style.textDecoration="underline";}

function setInactiveLink(indexParam){
    // document.links[indexParam].style.fontWeight="normal";
    document.links[indexParam].style.color="#000000";
    document.links[indexParam].style.textDecoration="none";}

function setOverImage(imageParam){
	var currentIndex=getArrayIndex(imageParam);
	if ((imageParam !="") && (imageParam !="home")) document.images[imageParam].src=img_active.src;
//	if (imageParam !="") document.images[imageParam].src=img_active.src;
	document.images[imageParam].src=img_active.src;
    setActiveLink(currentIndex);}

function setOutImage(imageParam){
    if (img_current==imageParam) 
        return true;
	var currentIndex=getArrayIndex(imageParam);
	if ((imageParam !="") && (imageParam !="home")) document.images[imageParam].src=img_inactive.src;
//	if (imageParam !="") document.images[imageParam].src=img_inactive.src;
	setInactiveLink(currentIndex);}

function setSelectImage(imageParam){
    var previous_Value=0;
    var current_Value=0;
    previous_Value=getArrayIndex(img_current);
    if (previous_Value == -1) previous_Value=0;
        current_Value=getArrayIndex(imageParam);
   if ((img_current !="") && (img_current !="home")) document.images[img_current].src=img_inactive.src; 
 //   if (img_current !="") document.images[img_current].src=img_inactive.src; 
    img_current=imageParam;
	if (img_current !="home") document.images[img_current].src=img_active.src;
//	document.images[img_current].src=img_active.src;
    setInactiveLink(previous_Value);
    setActiveLink(current_Value);}

/*function restoreCookies(name_param){
    var cookie_name = name_param;
    var allcookies = document.cookie;
    var cookie_pos = allcookies.indexOf(cookie_name);
    if (cookie_pos != -1){
    	var cookie_offset = cookie_name.length;
    	var cookie_start = cookie_pos + cookie_offset;
    	var cookie_end = allcookies.indexOf(";", cookie_start);
    	if (cookie_end == -1){ cookie_end=allcookies.length;}
    	var cookie_value=allcookies.substring(cookie_start, cookie_end);
    	cookie_value=unescape(cookie_value);
       } else cookie_value="'no'"; return cookie_value; }*/

 function CheckAllFieldsContact(){
   if (document.forms[0].remarks.value=="") {
    alert ("Please, fill in the Comments field!");
    return false;}
   if (document.forms[0].email.value=="") {
    alert ("Please, fill in E-mail field!");
    return false;}
   if ((document.forms[0].email.value.indexOf("@")==-1) || (document.forms[0].email.value.indexOf(".")==-1)) {
    alert ("Incorrect E-mail field!");
    return false;}
 return true; }

  function CheckAllFieldsGuest(){
   if ((document.forms[0].guest_name.value=="") || (document.forms[0].comments.value == "") || (document.forms[0].userInput.value == "")) {
    alert ("Please, fill in all required fields!");
    return false;}
	if ((document.forms[0].guest_email.value!="") && (document.forms[0].guest_email.value.indexOf("@") == -1)){
	    alert ("Please, enter a valid E-mail address!");
	    return false;}
    return true; }






