function NewWindow(mypage, myname, w, h, scroll) {
var winl = (screen.width - w) / 2;
var wint = (screen.height - h) / 2;
winprops = 'height='+h+',width='+w+',top='+wint+',left='+winl+',scrollbars='+scroll+',resizable=0'
win = window.open(mypage, myname, winprops)
if (parseInt(navigator.appVersion) >= 4) { win.window.focus(); }
}


function validar(t)
{
if (document.frmfale.nome.value.length < 6)
   {
   alert('O campo nome deve ser preenchido com pelo menos 6 caracteres.');
   document.frmfale.nome.focus();
   return false;
   }
else if (document.frmfale.endereco.value.length < 6)
   {
   alert('O campo ENDEREÇO deve ser preenchido com pelo menos 6 caracteres.');
   document.frmfale.endereco.focus();
   return false;
   }
else if (document.frmfale.cep.value.length < 6)
   {
   alert('O campo CEP deve ser preenchido com pelo menos 6 caracteres.');
   document.frmfale.cep.focus();
   return false;
   }
else if (document.frmfale.email.value.length < 6)
   {
   alert('O campo E-MAIL deve ser preenchido com pelo menos 6 caracteres.');
   document.frmfale.email.focus();
   return false;
   }
else if (document.frmfale.texto.value.length < 6)
   {
   alert('O campo Mensagem deve ser preenchido com pelo menos 6 caracteres.');
   document.frmfale.texto.focus();
   return false;
   }
else
   {
   window.open("", t, "width=400,height=250");
   return true;
   }
}

function openWin(winName, urlLoc, w, h, showStatus, isViewer) {
l = (screen.availWidth - w)/2;
t = (screen.availHeight - h)/2;
features  = "toolbar=no";      // yes|no 
features += ",location=no";    // yes|no 
features += ",directories=no"; // yes|no 
features += ",status=" + (showStatus?"yes":"no");  // yes|no 
features += ",menubar=no";     // yes|no 
features += ",scrollbars=" + (isViewer?"yes":"no");   // auto|yes|no 
features += ",resizable=" + (isViewer?"yes":"no");   // yes|no 
features += ",height=" + h;
features += ",width=" + w;
features += ",left=" + l;
features += ",top=" + t;
window.open(urlLoc,winName,features);
} 

function winopen(url)
{
win=window.open(url,'movimento','Resizable,ScrollBars');
}


