//Chamada de inicio do AJAX
try {
    netscape.security.PrivilegeManager.enablePrivilege("UniversalBrowserRead");
   } catch (e) {
    //alert("Permission UniversalBrowserRead denied.");
   }

try{
    xmlhttp = new XMLHttpRequest();
}catch(ee){
    try{
        xmlhttp = new ActiveXObject("Msxml2.XMLHTTP");
    }catch(e){
        try{
            xmlhttp = new ActiveXObject("Microsoft.XMLHTTP");
        }catch(E){
            xmlhttp = false;
        }
    }
}

function validaCampos() {
	form = document.form_news;
	if (form.nome.value == '| Nome ') 
		form.nome.value = '';
	if (form.email.value == '| E-mail ') 
		form.email.value = '';
}

function MM_openBrWindow(theURL,winName,features, larg, alt) { //v2.0
  window_ = open(theURL,winName,features);
  window_.moveTo((screen.width-larg)/2,(screen.height-alt)/2-20);
}

function janela( file, winName, larg,  alt){
//features = 'directories=no,toolbar=no,location=no,status=no,menubar=no,scrollbars=yes,copyhistory=no,resizable=no,width=' + larg + ',height='  + alt);
	features = 'scrollbars=yes,width=' + larg + ',height='  + alt;
	window_ = open(file,winName,features);
    window_.moveTo((screen.width-larg)/2,(screen.height-alt)/2-20);
}

function toggle(theElem){
	document.getElementById(theElem).style.display = (document.getElementById(theElem).style.display == 'none')?'block':'none';
	//document.getElementById(theElemb).style.display = (document.getElementById(theElemb).style.display == 'none')?'block':'none';
	//document.getElementById(theElemc).style.display = (document.getElementById(theElemc).style.display == 'none')?'block':'none';
}