function do_check(button_name)
	{
		if(event.keyCode == '13')
		{
			
			var elem = document.getElementById(button_name + "_1");
			
			if (elem == null)
				elem = document.getElementById(button_name);
			
			//alert(elem);			
			

			elem.focus();
			//eval('document.all.'+button_name).focus();
			//document.all.Submit.click();
		}
	}

	function CheckLanguage(string_to_check)
	{
		var curr_char;
		
		for (i=0; i<=string_to_check.length; i++)
		{
			curr_char = string_to_check.charCodeAt(i);
			if (curr_char>=1488 && curr_char<=1514)
				return "heb";
			if (curr_char>=1040 && curr_char<=1103)
				return "rus";
		}
		return "eng";			
	}

	function SetCookie(name,value,expires,path,domain,secure) {
		var today = new Date();
		today.setTime( today.getTime() );
		if ( expires )
		{
			expires = expires * 1000 * 60 * 60 * 24;
		}
		var expires_date = new Date( today.getTime() + (expires) );

		document.cookie = name + "=" +escape( value ) + ( ( expires ) ? ";expires=" + expires_date.toGMTString() : "" ) + ( ( path ) ? ";path=" + path : "" ) + ( ( domain ) ? ";domain=" + domain : "" ) +( ( secure ) ? ";secure" : "" );
	}

	function SetCookieForHours(name,value,expires,path,domain,secure) {
		var today = new Date();
		today.setTime( today.getTime() );
		if ( expires )
		{
			expires = expires * 1000 * 60 * 60;
		}
		var expires_date = new Date( today.getTime() + (expires) );

		document.cookie = name + "=" +escape( value ) + ( ( expires ) ? ";expires=" + expires_date.toGMTString() : "" ) + ( ( path ) ? ";path=" + path : "" ) + ( ( domain ) ? ";domain=" + domain : "" ) +( ( secure ) ? ";secure" : "" );
	}

	function GetCookie(name){
	var start = document.cookie.indexOf(name+"=");
	//alert(name);
    var len = start+name.length+1;
    if ((!start) && (name != document.cookie.substring(0,name.length))) return null;
    if (start == -1) return null;
    var end = document.cookie.indexOf(";",len);
    if (end == -1) end = document.cookie.length;
    return unescape(document.cookie.substring(len,end));
	}
	
	function OpenWindow(url,name,sizes)
	{
		var newWin = window.open(url,name,sizes);
		newWin.focus();
	}
	
	
	
	function OpenSearchPageInSeparateWindow(engine_name, searchID)
	{
			var word = document.getElementById(searchID).value;
			if (engine_name == 'submit')
			{	
				OpenWindow('http://search.zahav.ru/SearchPage.aspx?q='+escape(word.replace('\'', '\\\''))+'&search_type=web', '', '');	
			}			
	}
	
	function OpenSearchPageInSameWindow(engine_name, searchID)
	{
			var word = document.getElementById(searchID).value;
			if (engine_name == 'submit')
			{	
				document.location.href='http://search.zahav.ru/SearchPage.aspx?q='+escape(word.replace('\'', '\\\''))+'&search_type=web';	
			}			
	}
	
	
		
	
	
	
	function searchEngines()
	{
		window.location = "http://search.zahav.ru/SearchPage.aspx?advanced=1";
		//OpenWindow('/SearchEngines.aspx','','scrollbars=no,status=no,width=380,height=280,top=64,left=64');
	}	
	
	
	
	
	
function IsIE()
{
	if (window.navigator.appName.toLowerCase().indexOf("microsoft") > -1) 
		return true;
	else
		return false;
}


<!----------------------------------------------------------->
<!----------- Begin Script For DDL Search Type -------------->
<!----------------------------------------------------------->



function OnHoroSignMouseOver()
{
	event.srcElement.style.cursor = "hand";
	event.srcElement.style.filter = "progid:DXImageTransform.Microsoft.Alpha(opacity=60);}";
}
	
function OnHoroSignMouseOut()
{
	event.srcElement.style.cursor = "default";
	event.srcElement.style.filter = "progid:DXImageTransform.Microsoft.Alpha(opacity=100);}";
}



<!----------------------------------------------------------->
<!-------------- End Script For DDL Search Type ------------->
<!----------------------------------------------------------->




<!----------------------------------------------------------->
<!-------------- Begin Script For Campaign ------------------>
<!----------------------------------------------------------->




/*


    
if (GetCookie("Campaign") == null)
{
	window.attachEvent("onunload", ShowCampaign);
}



function ShowCampaign()
{
	if (window.screenTop > 9999)
	{
		
		var t = "height=" + window.screen.height + ", width=" + window.screen.width + ", left=0, top=0, location=0, menubar=0, resizable=0, scrollbars=0, status=0, titlebar=0, toolbar=0";
		window.open("/Campaign.aspx", null, t);
		
		
		window.self.opener = window.self;
		window.self.close();
	}
}


			//window.attachEvent("onunload", GetStatictics);
			
			function GetStatictics()
			{
				
				//if (window.screenTop > 9999)
				//{
					if (GetCookie("Campaign") == null)
					{
						var requestURL=document.location.href;
						document.getElementById("StaticticsImg").src ='/Campaign.aspx?requestURL='+requestURL;
						SetCookie("Campaign",'true',3600,'/','zahav.ru',false)
						//http://switch6.castup.net/frames/20060222_barak/opener_js.asp;
						castup_openWindow();
						
					}
				//}
				
				
			}
			function castup_openWindow()
{
	try
	{
		wid = eval(window.screen.availWidth);
		hei = eval(window.screen.availHeight);
//		wid = eval(window.screen.width);
//		hei = eval(window.screen.height);

//		var win = javascript:window.open("","video","fullscreen=1");
//		var win = window.open("","video","width="+wid+",height="+hei+",top=0,left=0,fullscreen=1,titlebar=0,toolbar=0,menubar=0,resizable=0,scrollbars=0,channelmode=0");
//		win.blur();

		for (var i = 0; i < 50; ++i)
			setTimeout("window.focus()", i * 25);

		var videoSizeStr = "1024x768";

		try
		{
			var screenWidth		= eval(window.screen.width);
			var screenHeight	= eval(window.screen.height);

			if (screenWidth < 1024 || screenHeight < 768)
			{
				videoSizeStr = '800x600';				
			}
		}
		catch(e)
		{
		}

		var sURL = "";
	
		sURL = "http://switch6.castup.net/frames/20060222_barak/800x600/video.asp";
		//sURL = "800x600/video.asp";
		
		//var win = window.open(sURL,"video","fullscreen=yes");
		var win = window.open(sURL,"video","width="+wid+",height="+hei+",fullscreen=no,titlebar=0,toolbar=0,menubar=0,resizable=0,scrollbars=0,channelmode=0,top=0,left=0");
		win.blur();

		//		win.location.href = videoSizeStr + "/video.asp?debugmode=1";
		//		win.location.href = videoSizeStr + "/video.asp";

//		win.location.href = "http://switch6.castup.net/frames/20050727_nokia/" + videoSizeStr + "/video.asp";
//		win.location.href = "800x600/video.asp";
	}
	catch(e)
	{
	}
}
*/
<!----------------------------------------------------------->
<!-------------- End Script For Campaign -------------------->
<!----------------------------------------------------------->

