//функция для перехода на др. стр. по флэш банерам с сохранением refere
function openURLref(fullurl) {
if(document.all) {
document.links('aaa').href = fullurl;
document.links('aaa').click();
}
else {
location.href=fullurl;
}}


//проверка наличия запроса и направление в нужную область поиска для портала

function CheckSearchForm(theForm) {
	if (theForm.text.value == "")
	 {
		alert("Отсутствует строка поиска");
		theForm.text.focus();
		return (false);
	 }
	if (theForm.text.value.length < 2)
	 {
		alert("Слишком короткое слово");
		theForm.text.focus();
		return (false);
	 }
	if (theForm.text.value.length > 35)
	 {
		alert("Слишком длинная фраза");
		theForm.text.focus();
		return (false);
	 }
/*
	if (theForm.placeofsearch[0].checked)
	{
		theForm.action="/services/search/search_results.asp";
		theForm.submit();
	}
	if (theForm.placeofsearch[1].checked)
	{
		theForm.action="http://search.report.ru/scripts/search.exe";
		theForm.submit();
	}
	return (false);
*/
	theForm.submit();
}

//проверка наличия запроса и направление в нужную область поиска для главной страницы
function CheckMainSearchForm(theForm) {
	if (theForm.searchword.value == "")
	 {
		alert("Отсутствует строка поиска");
		theForm.searchword.focus();
		return (false);
	 }
	if (theForm.searchword.value.length < 2)
	 {
		alert("Слишком короткое слово");
		theForm.searchword.focus();
		return (false);
	 }
	if (theForm.searchword.value.length > 35)
	 {
		alert("Слишком длинная фраза");
		theForm.searchword.focus();
		return (false);
	 }
/*	if (theForm.placeofsearch[0].checked)
	{
		theForm.action="/search_results.asp";
		theForm.submit();
	}
	if (theForm.placeofsearch[1].checked)
	{
		theForm.action="http://search.report.ru/scripts/search.exe";
		theForm.submit();
	}
	return (false);
*/
	theForm.submit();
}

//проверка наличия запроса на форуме
function CheckForumSearchForm(theForm) {
	if (theForm.searchword.value == "")
	 {
		alert("Отсутствует строка поиска");
		theForm.searchword.focus();
		return (false);
	 }
	if (theForm.searchword.value.length < 2)
	 {
		alert("Слишком короткое слово");
		theForm.searchword.focus();
		return (false);
	 }
	if (theForm.searchword.value.length > 35)
	 {
		alert("Слишком длинная фраза");
		theForm.searchword.focus();
		return (false);
	 }
		theForm.submit();
}
