function Search(submit, root) {


form = document.getElementById("frm_search");
  area="";
if(form.area.value == "news")
  area="news/";
if(form.area.value == "article")
  area="article/";
  if (form.edt_search_text.value == "") {
      alert('Please enter search text');
    form.edt_search_text.focus();
    if (submit)
      return false;
  } else {
    re = /[ ]/g;
    document.location = root + area + 'result/'+ form.edt_search_text.value.replace(re, "_");
    if (submit)
      return false;
  }

};

function switch_mode(form, control, value) {

  form = document.getElementById(form);
  ctrl = document.getElementById(control);
  ctrl.value = value;
  form.submit();

};

function do_click(src) { 
  document.getElementById(src.id + "_a").click(); 
}

function smenu_hover(src) { 
  src.style.cursor = 'hand';	
  src.className = 'leftmenu_hover'; 
}

function smenu_out(src)	{ 
  src.style.cursor = 'default';	
  src.className = 'leftmenu'; 
}

function broken_links(id_site,url)
{
	if(window.confirm("Are you sure  "+url+"  is in Error?"))
	{
	 var  path = document.location.href;
	 var add_path = "brlinks/"+id_site;
	 var  new_path = path.replace("service",add_path);
	 document.location = new_path;
	 return true;
	}
	else
	{
		return false;
	}  	
}


function broken_linkh(id_site,url)
{
	if(window.confirm("Are you sure  "+url+"  is in Error?"))
	{
		var  path = document.location.href;
		var add_path = "brlinkh/"+id_site;
    	var  new_path = path.replace("result",add_path);
	 document.location = new_path;
	 return true;
	}
	else
	{
		return false;
	}  	
}

function __OpenUrlHelp(url, full_window) {
  
  wnds_params = 'menubar=1,resizable=1,scrollbars=1,width=620,height=800';
  if (full_window)
    wnds_params = '';
   
  w = window.open(url, '_blank', wnds_params, true);
  w.focus();
   return false;

}