
	if (document.images) {
		approachOn = new Image
		approachOff = new Image
		featuredOn = new Image
		featuredOff = new Image
		collectionsOn = new Image
		collectionsOff = new Image
		stockOn = new Image
		stockOff = new Image
		contactOn = new Image
		contactOff = new Image
		approachOn.src = "images/links_approach_on.gif"
		approachOff.src = "images/links_approach_off.gif"
		featuredOn.src = "images/links_featured_on.gif"
		featuredOff.src = "images/links_featured_off.gif"
		collectionsOn.src = "images/links_collections_on.gif"
		collectionsOff.src = "images/links_collections_off.gif"
		stockOn.src = "images/links_stock_on.gif"
		stockOff.src = "images/links_stock_off.gif"
		contactOn.src = "images/links_contact_on.gif"
		contactOff.src = "images/links_contact_off.gif"

	} else {
		approachOn = ""
		approachOff = ""
		featuredOn = ""
		featuredOff = ""
		collectionsOn = ""
		collectionsOff = ""
		stockOn = ""
		stockOff = ""
		contactOn = ""
		contactOff = ""
		document.approach = ""
		document.featured = ""
		document.collections = ""
		document.stock = ""
		document.contact = ""

	}



function openwindow()
	{
	w_height=screen.availHeight - 30
	w_width=screen.availWidth - 10
		
		window.open("gallery2.php","my_new_window","toolbar=no, location=no,directories=no, status=no, top=0,left=0" +
	"menubar=no, scrollbars=yes, resizable=yes, copyhistory=yes, height=" + w_height + ",width=" + w_width )
	}



function locate(){
		window.location="bookmark.php"
	}


    function validateNotBlank(value){
		if(value=="" || value==null){
			return false;
		}
		return true;
    }//end function 



      function checkRadio(value){
	    radioOption= -1;
		for (i=0; i<value.length; i++){
			if (value[i].checked)
			radioOption= 1;
		}
		if (radioOption == -1){
		  return false;
		}
		return true;
      }//end function 



      function validateEmail(value){
           var notValid=false;
			if(value=="" || value==null){
					notValid=true;
			}
		
			invalidChars=" /:;',$#!%^&*()+={}[]<>|";
			for(i=0; i<invalidChars.length; i++){
				var badChar = invalidChars.charAt(i);
				if (value.indexOf(badChar,0) != -1){ notValid=true;}
			}
		
			//test for @ sign
			if (value.indexOf("@",1) == -1) notValid=true;
		
			//test for period
			if (value.indexOf(".",1) == -1) notValid=true;
		
			if (notValid==true){
				return false;
			}else{
				return true;
			}
       }//end function 



      function validateDate(value){
           var notValid=false;
			if(value=="" || value==null){
					notValid=true;
			}
		
			invalidChars="@. :;',$#!%^&*()+={}[]<>|abcdefghijklmnopqrstuvwxyz";
			for(i=0; i<invalidChars.length; i++){
				var badChar = invalidChars.charAt(i);
				if (value.indexOf(badChar,0) != -1){ notValid=true;}
			}
		
			//test for / sign
			if (value.indexOf("/",1) == -1) notValid=true;
		
			//test for length
			if (value.length != 10) notValid=true;
		
			if (notValid==true){
				return false;
			}else{
				return true;
			}
       }//end function 



		function OpenPopup(pagename,sentwidth,sentheight){
		        var URL = pagename; 
		        remoteWin = window.open(URL, "remotewindow" + sentwidth + sentheight, "resizable=yes,toolbar=0,location=0,directories=0,status=0,menubar=0,scrollbars=1,copyhistory=0,width=" + sentwidth + ",height=" + sentheight + ",top=10,left=10,screenX=10,screenY=10");
		        remoteWin.location = URL;
		        remoteWin.focus();
		}





	function updateParent(textField,fieldName) {
	
		textField =	unescape(textField)
		opener.document.aform.fieldName.value = textField
		opener.focus()
		window.close()
	}












