	<!--

		/* --------------------------- STANDARD ROUTINES --------------------------- */

		var ns4 = (document.layers);
		var ie4 = (document.all && !document.getElementById);
		var ie5 = (document.all && document.getElementById);
		var ns6 = (!document.all && document.getElementById);

		function showMenu(where) {
			if (ns4) {
				document.layers[where].style.visibility="visible";
			} else if (ie4) {
				document.all[where].style.visibility="visible";
			} else if (ie5 || ns6) {
				document.getElementById(where).style.visibility="visible";
			}
		}

		function hideMenu(where) {
			if (ns4) {
				document.layers[where].style.visibility="hidden";
			} else if (ie4) {
				document.all[where].style.visibility="hidden";
			} else if (ie5 || ns6) {
				document.getElementById(where).style.visibility="hidden";
			}
		}

		function SwapText(where, what) {
			if (ns4) {
				document.layers[where].innerHTML=what;
			} else if (ie4) {
				document.all[where].innerHTML=what;
			} else if (ie5 || ns6) {
				document.getElementById(where).innerHTML=what;
			}
		}

		function GetText(where) {
			var theOrg;
			if (ns4) {
				theOrg = document.layers[where].innerHTML;
			} else if (ie4) {
				theOrg = document.all[where].innerHTML;
			} else if (ie5 || ns6) {
				theOrg = document.getElementById(where).innerHTML;
			}
			return theOrg;
		}

		function CheckEmail(dname,fname,msg) {
			var frmName = dname;
			var fldName = fname;
			var alertText = msg;
			var string1 = document[frmName][fldName].value;
			if ((string1.indexOf("@")==-1) || (string1.indexOf(".")==-1)) {
				alert(alertText);
				document[frmName][fldName].focus();
				return true;
			}
		}

		function CheckNull(dname,fname,msg) {
			var frmName = dname;
			var fldName = fname;
			var alertText = msg;
			var string1 = document[frmName][fldName].value;
			var string2 = string1.replace(/ /g, "");
			if (string2=="") {
				alert(alertText);
				document[frmName][fldName].focus();
				return true;
			}
		}

		function CheckLength(dname,fname,msg,max) {
			var frmName = dname;
			var fldName = fname;
			var alertText = msg;
			var maxLen = max - 0;
			var string1 = document[frmName][fldName].value;
			if (string1.length > maxLen) {
				alert(alertText);
				document[frmName][fldName].focus();
				return true;
			}
		}


		/* ------------------------------ STANDARD AJAX ---------------------------- */

		function PostItem(theScript, frmName, div) {
			frmName = document.forms[frmName];
			var fld;
			var theData = "";
			for (i = 0; i < frmName.elements.length; i++) {
				fld = frmName.elements[i];
				if ((fld.type !== "button") && (fld.type !== "submit")) {
					if ((fld.type == "radio") || (fld.type == "checkbox")) {
						if (fld.checked) {
							if (i > 0) {
								theData += "&" + fld.name + "=" + escape(fld.value);
							} else {
								theData += fld.name + "=" + escape(fld.value);
							}
						}
					} else {
						if (i > 0) {
							theData += "&" + fld.name + "=" + escape(fld.value);
						} else {
							theData += fld.name + "=" + escape(fld.value);
						}
					}
				}
			}
			var xmlHttp;
			if (xmlHttp = startAjax()) {
				xmlHttp.open("POST", theScript, true);
				xmlHttp.setRequestHeader("Content-Type", "application/x-www-form-urlencoded");
				xmlHttp.onreadystatechange = function() {
					if (xmlHttp.readyState == 4) {
						var theText = xmlHttp.responseText;
						showMenu(div);
						SwapText(div, theText);
					}
				}
				xmlHttp.send(theData);
			}
		}

		function GetItem(scrp, div, tmp) {
			var theScript = scrp + tmp;
			var xmlHttp;
			if (xmlHttp = startAjax()) {
				xmlHttp.onreadystatechange = function() {
					if(xmlHttp.readyState == 4) {
						var theText = xmlHttp.responseText;
						showMenu(div);
						SwapText(div, theText);
					}
				}
				xmlHttp.open("GET", theScript, true);
				xmlHttp.send(null);
			}
			if (tmp.indexOf("#") == 0) {
				document.location.href = tmp;
			}
		}

		function startAjax() {
			var xmlHttp;
			try {
				xmlHttp = new XMLHttpRequest();
			//	xmlHttp.overrideMimeType("text/xml");
			}
			catch (e) {
				try {
					xmlHttp = new ActiveXObject("Msxml2.XMLHTTP");
				}
				catch (e) {
					try {
						xmlHttp = new ActiveXObject("Microsoft.XMLHTTP");
					}
					catch (e) {
						alert("Your browser does not support AJAX.");
						return false;
					}
				}
			}
			return xmlHttp;
		}


		/* ----------------------------- SCRIPT SPECIFIC --------------------------- */

		function DoSearch() {
			var theMin = (document.frmSearch.minprice.value - 0);
			var theMax = (document.frmSearch.maxprice.value - 0);
			if (theMax < theMin) {
				alert("Your maximum price must be greater than or equal to your minimum price.");
				document.frmSearch.maxprice.focus();
				return false;
			}
			if (theMax == 0) {
				alert("Your maximum price must be greater than zero.");
				document.frmSearch.maxprice.focus();
				return false;
			}
			document.frmSearch.r.value = Math.random();
			PostItem("../search/srShowList.php", "frmSearch", "content");
			hideMenu("FlashImageLayer");
		}

		function TurnPage(page, src) {
			document.frmSearch.thispage.value = page;
			document.frmSearch.r.value = Math.random();
			PostItem("../search/srShowList.php", "frmSearch", "content");
			document.location.href="#top";
		}

		function DoLogin() {
			var theID = document.frmLogin.logid.value;
			var thePW = document.frmLogin.logpw.value;
			theID = theID.replace(/ /g, "");
			thePW = thePW.replace(/ /g, "");
			if ((theID == "rad") && (thePW == "rad798")) {
				GetItem("../vasdf/admMenu.php?r=" + Math.random(), "vcontent", "");
			} else {
				GetItem("../vasdf/admLogin.php?r=" + Math.random(), "vcontent", "");
				setTimeout("document.frmLogin.logid.focus()", 500);
			}
		}

		function DoSpots() {
			PostItem("../vasdf/admMenu.php", "frmSpots", "vcontent");
		}

		function FixPager() {
			document.frmSearch.thispage.value = "1";
		}

		function GetSpots() {
			GetItem("../spotlight/spList.php", "scontent", "");
			hideMenu("FlashImageLayer");
		}

		function GetProfile(theID, theSrc) {
			var theWhere;
			if (theSrc == "search") {
				theWhere = "content";
			} else {
				theWhere = "scontent";
			}
			GetItem("../profile/index.php?id=" + theID + "&src=" + theSrc + "&r=" + Math.random(), theWhere, "");
			var theBox = GetText("FlashImageLayer");
			SwapText("FlashImageLayer", "");
			SwapText("FlashImageLayer", theBox);
			showMenu("FlashImageLayer");
			document.location.href="#top";
		}

		function DoLogs() {
			var theDate = document.frmLogs.thedate.value;
			GetItem("../vasdf/admAutolog.php?thedate=" + theDate + "&r=" + Math.random(), "vcontent", "");
		}

	-->
