<!--

var maprov = "pentalog.ro";

function nouv_fenetre(chemin,nom,params) {
  window.open(chemin,nom,params);
}

function veriform() {
  document.forms.rech.query.value = document.forms.rech.query.value.replace(/(^\s*)|(\s*$)/g,'');
  if (document.forms.rech.query.value=="") {
    document.forms.rech.query.focus();
    alert('Veuillez remplir correctement le champ de recherche.');
  }
  else {
    if (document.forms.rech.typerech[0].checked==false && document.forms.rech.typerech[1].checked==false) {
      document.forms.rech.query.focus();
      alert('Veuillez préciser le type de votre recherche (Infos/Compétences).');
    }
    else goSearch();
  }
}

function goSearch() {
  var choix;
  for (i=0;i<document.forms.rech.typerech.length;i++) {
    if (document.forms.rech.typerech[i].checked==true) {
      choix = document.forms.rech.typerech[i].value;
      break;
    }
  }
  var researchURL;
  switch (choix) {
    case '1': researchURL = "/search/resultsite.jsp?query="+document.rech.query.value+"&prov="+maprov+"&lang=RO"; break;
    case '2': researchURL = "/search/resultcomp.jsp?query="+document.rech.query.value+"&prov="+maprov+"&lang=RO"; break;
    default:  researchURL = "/search/resultsite.jsp?query="+document.rech.query.value+"&prov="+maprov+"&lang=RO";  break;
  }
  var width = 830;
  var height = 500;
  var xpos = 100; //(window.screen.width-width)/2;
  var ypos = 100; //(window.screen.height-height)/2;
  var attr1 = "left="+xpos+",top="+ypos+",width="+width+",height="+height;
  var attr2 = ",location=no,menubar=no,toolbar=no,status=no,scrollbars=yes,resizable=yes";
  nouv_fenetre(researchURL,'',attr1+attr2)
}


//-->
