function open_new(url)
  {
    if (window.screen)
    {
      var w = screen.width;
      var h = screen.height;
      var center_x = w / 2;
      var center_y = h / 2;
      var new_width;
      var new_height;
      var new_left;
      var new_top;

      if(w <= 800)
      {
        new_width  = 400;
        new_height = 400;
        new_left   = center_x - (new_width / 2);
        new_top    = center_y - (new_height / 2);
      }

      if(w > 800)
      {
        new_width  = 700;
        new_height = 500;
        new_left   = center_x - (new_width / 2);
        new_top    = center_y - (new_height / 2);
      }

      var new_Window = window.open(url, "", "menubar=no, location=no, status=no, toolbar=no, scrollbars=auto, resizable=no , width=" + new_width + ", height=" + new_height + ", top=" + new_top + ", left=" + new_left + "");
      new_Window.focus();
    }
  }

function open_locatie(url)
  {
    if (window.screen)
    {
      var w = screen.width;
      var h = screen.height;
      var center_x = w / 2;
      var center_y = h / 2;
      var new_width;
      var new_height;
      var new_left;
      var new_top;

      new_width  = 610;
      new_height = 560;
      new_left   = center_x - (new_width / 2);
      new_top    = center_y - (new_height / 2);

      var new_Window = window.open(url, "", "menubar=no, location=no, status=no, toolbar=no, scrollbars=auto, resizable=no , width=" + new_width + ", height=" + new_height + ", top=" + new_top + ", left=" + new_left + "");
      new_Window.focus();
    }
  }


function entsub(myform) {
  if (window.event && window.event.keyCode == 13)
    myform.submit();
  else
    return true;
}

function CautareSite() {
	f_cautare_site.submit();
}

function OpenNewWindow(url, lungime, latime, denumire, scrol){
    if (window.screen){
      var w = screen.width;
      var h = screen.height;
      var center_x = w / 2;
      var center_y = h / 2;
      var new_width;
      var new_height;
      var new_left;
      var new_top;

      new_width  = lungime;
      new_height = latime;
      new_left   = center_x - (new_width / 2);
      new_top    = center_y - (new_height / 2);

      var new_Window = window.open(url, denumire, "menubar=no, location=no, status=no, toolbar=no, scrollbars=" +scrol+", resizable=no , width=" + new_width + ", height=" + new_height + ", top=" + new_top + ", left=" + new_left + "");
      new_Window.focus();
    }
}

function Listeaza()
    {
        if (!window.print)
         {
            return;
         }
         window.print();
}

function Confirmare(URL,mesaj)
{
  if (window.confirm(mesaj))
     window.location.href=URL;
}

