function image(img) {
	mywin = window.open ('/showimage.php?id='+img,'imwin', 'width=100, height=100, toolbar=no, location=no, scrollbars');
	mywin.focus();
}

function showclassifiedimage(img) {
	mywin = window.open ('/showimage.php?classified='+img,'imwin', 'width=100, height=100, toolbar=no, location=no, scrollbars');
	mywin.focus();
}

function checkemail(email) {
	var filter=/^([\w-]+(?:\.[\w-]+)*)@((?:[\w-]+\.)*\w[\w-]{0,66})\.([a-z]{2,6}(?:\.[a-z]{2})?)$/i;
	if (filter.test(email)) {
		return true;
	} else {
		return false;
	}
}

function checkvisible(password)	{
		var filter=/([\x21-\x7E])/i;
	if (filter.test(password)) {
		return true;
	} else {
		return false;
	}
	
}


//sorts out rollovers for search results in Win IE

sfHover = function() {
	if (document.getElementById("searchres")) {
		var sfEls = document.getElementById("searchres").getElementsByTagName("li");
		for (var i=0; i<sfEls.length; i++) {
			sfEls[i].onmouseover=function() {
				this.className+=" sfhover";
			}
			sfEls[i].onmouseout=function() {
				this.className=this.className.replace(new RegExp(" sfhover\\b"), "");
			}
		}
	}
}
if (window.attachEvent) window.attachEvent("onload", sfHover);

