function SearchChek22()
{

var s1=window.document.forms.forma_search.search_product_total.value;


if (s1=="" || s1==" " || s1=="  " || s1=="   " || s1=="Я ищу...")
{
 alert("Ошибка заполнения формы поиска!");
 return false;
}
else 
{
  document.forma_search.submit();
}
return true;
}



function win_open(href, win_name)
{
	strFeatures="toolbar=no, menubar=no, directories=no, status=yes, width=170, height=10, top=00, left=00, location=no, scrollbars=no, resizable=yes";
	window.open(href, win_name, strFeatures);
}

function submit_click (checked_form)
{  
  checked_form.submit(); 
} 

function getBrowserInfo() {
 var t,v = undefined;
 if (window.opera) t = 'Opera';
 else if (document.all) {
  t = 'IE';
  var nv = navigator.appVersion;
  var s = nv.indexOf('MSIE')+5;
  v = nv.substring(s,s+1);
 }
 else if (navigator.appName) t = 'Netscape';
 return {type:t,version:v};
}

function bookmark(a){
 var url = window.document.location;
 var title = window.document.title;
 var b = getBrowserInfo();
 if (b.type == 'IE') window.external.AddFavorite(url,title);
 else if (b.type == 'Opera') {
  a.href = url;
  a.rel = "sidebar";
  a.title = url+','+title;
  return true;
 }
 else if (b.type == "Netscape") window.sidebar.addPanel(title,url,"");
 else alert("Нажмите CTRL-D, чтобы добавить страницу в закладки.");
 return false;
}

function compare_confirm(_id, sms)
{
  reason=false

  if (window.confirm(sms))
	{
    obj = document.getElementById(_id)
    reason=true
  }
  
  if(reason) obj.submit() 
}

function delete_confirm(del_url,sms)
{
	if (window.confirm(sms))
	{
		document.location = del_url;
	} 
	return false;
} // end function news_delete_confirm()


function img_window(img_name,img_tytle,img_size)
{
	imgw=window.open(img_name,"", "left=10, top=10, resizable=yes, toolbar=no, scrollbars=no, "+img_size);
	imgw.focus();
}

function ans_window(img_name,img_tytle,img_size)
{
	imgw=window.open(img_name,"", "left=10, top=10, resizable=yes, toolbar=no, scrollbars=yes, "+img_size);
	imgw.focus();
}

function Cursor(id, color) 
{
	var tr_id;
	tr_id = "tr_" + id;
	// window.alert("tr_id="+tr_id);
	document.all[tr_id].style.background = color;
	// window.event.srcElement.style.cursor = 'hand';
}

function submit_form(_id){
  obj = document.getElementById(_id)
  obj.submit() 
}
