var buttonpressed=0;

function tidyquicksearch()
{
	document.quicksearch.first.value = trim(document.quicksearch.first.value);
	document.quicksearch.last.value  = trim(document.quicksearch.last.value);

	return (true);
}

function getoutofframes()
{
	if (top.location)
	{
		if (top.location != parent.location) 
		{
			top.location = parent.location;
		}
	}
}

function focusFirst()
{
	if (document.tellme)
	{
		if (document.tellme.youremail)
		{
			document.tellme.youremail.focus();
		}
	}
}


function submitTellme()
{
	if (buttonpressed)
	{
		alert("sending request - please wait");
		return (false);
	}
	else
	{
		if (document.tellme.youremail.value == "")
		{
			alert("please enter your email address");
			document.tellme.youremail.focus();
			return (false);
		}
		else
		{
			buttonpressed=1;
	
			getScreenSize();

			return (true);
		}
	}
}

function getScreenSize()
{
	browser = (((navigator.appName == "Netscape") && (parseInt(navigator.appVersion) >= 3 )) || ((navigator.appName == "Microsoft Internet Explorer") && (parseInt(navigator.appVersion) >= 4 )))

	if (browser)
	{
		document.tellme.screen_width.value = screen.width;
		document.tellme.screen_height.value = screen.height;
	}
	else
	{
		document.tellme.screen_width.value = "na";
		document.tellme.screen_height.value = "na";
	}
}

function imagepopup(url)
{
	window.open(url,'imagepopup','height=450,width=600,scrollbars=yes,resizable=yes');
}

