function MM_closeWindow() { //v2.0
  window.close();
}

function MM_openBrWindow(theURL,winName,features) { //v2.0
  window.open(theURL,winName,features);
}

function getCookieVal (offset)
{
  var endstr = document.cookie.indexOf (";", offset);
  if (endstr == -1)
    endstr = document.cookie.length;
   return unescape(document.cookie.substring(offset, endstr));
}

function GetCookie (name)
{
  var arg = name + "=";
  var alen = arg.length;
  var clen = document.cookie.length;
  var i = 0;
  while (i < clen)
        {
        var j = i + alen;
        if (document.cookie.substring(i, j) == arg)
                return getCookieVal(j);
                i = document.cookie.indexOf(" ", i) + 1;
                if (i == 0) break;
        }
  return null;
}

window.document.cookie = "query_string=" + "" + ";expires=null;path=/;"
window.document.cookie = "invalidpnos=" + "" + ";expires=null;path=/;"

<!-- DHTML Menue For IE -->

function findObj(n, d) { 

var p,i,x;  
	if(!d) d=document; 
	if((p=n.indexOf("?"))>0&&parent.frames.length) {
    d=parent.frames[n.substring(p+1)].document; n=n.substring(0,p);
	}

  if(!(x=d[n])&&d.all) x=d.all[n]; for (i=0;!x&&i<d.forms.length;i++) x=d.forms[i][n];
  for(i=0;!x&&d.layers&&i<d.layers.length;i++) x=findObj(n,d.layers[i].document); return x;
}

function showHideLayers() {

var i,p,v,obj,
args=showHideLayers.arguments;

	for (i=0; i<(args.length-2); i+=3)
	
	if ((obj=findObj(args[i]))!=null) { 
	v=args[i+2];

  			if (obj.style) {
			obj=obj.style; 
			v=(v=='show')?'visible':(v='hide')?'hidden':v; 
			}
    obj.visibility=v;
	}
	
}

<!-- DHTML Menue For NS4 -->

//Script anti-frame
if(top.frames.length!=0){top.location=location;}
var IE4 = document.all; NS4 = document.layers; NS6 = document.getElementById;
function getStyle(id){return NS4 ? document[id] : NS6 ? document.getElementById(id).style : document.all[id].style;}
function hideDiv(id){getStyle(id).visibility = NS4 ? "hide" : "hidden";}
function showDiv(id){getStyle(id).visibility = NS4 ? "show" : "visible";}
function openPop(URL, target, w, h, scroll, resize) {
	window.open(URL, target, 'height=' + h + ',width=' + w + ',top=' + (screen.height - h) / 2 + ',left=' + (screen.width - w) / 2 + ',scrollbars='+scroll+',resizable=0').window.focus();
}
// script dhtml dos menus superiores"
function HideLayer(layer){hideDiv(layer);}
function ShowLayer(layer){showDiv(layer);}
function showHideLayers2(layer){hideDiv(layer);}
function showHideLayers1(layer){showDiv(layer);}

	var hoje = new Date();
	var dia = hoje.getDate();
	var dias = hoje.getDay();
	var mes = hoje.getMonth();
	var ano = hoje.getYear();
	
	if (dia < 10)
		dia = "0" + dia
	if (ano < 2000)
	              ano = ano + 1900;
    
    function CriaArray (n) {
	this.length = n }
	NomeDia = new CriaArray(7)
	NomeDia[0] = "Domingo"
	NomeDia[1] = "Segunda"
	NomeDia[2] = "Ter&ccedil;a"
	NomeDia[3] = "Quarta"
	NomeDia[4] = "Quinta"
	NomeDia[5] = "Sexta"
	NomeDia[6] = "S&aacute;bado"

	NomeMes = new CriaArray(12)
	NomeMes[0] = "Janeiro"
	NomeMes[1] = "Fevereiro"
	NomeMes[2] = "Mar&ccedil;o"
	NomeMes[3] = "Abril"
	NomeMes[4] = "Maio"
	NomeMes[5] = "Junho"
	NomeMes[6] = "Julho"
	NomeMes[7] = "Agosto"
	NomeMes[8] = "Setembro"
	NomeMes[9] = "Outubro"
	NomeMes[10] = "Novembro"
	NomeMes[11] = "Dezembro"

function WriteDate() {
	document.write ("" + NomeDia[dias] + ", " + dia + " de " + NomeMes[mes] + " de " + ano + "")
}

function WriteMes() {
	document.write (NomeDia[dias])
}


function valida_campo()
// criamos a função valida_campo()
{
  <!--
  // para cada campo do formulário, vamos fazer a verificação para não aceitar valores nulos
  var nome = document.form.Nome.value
  if (nome=='Seu Nome')
  {
    // caso algum campo fique em branco, mostraremos uma caixa de alerta
    alert("Entre com seu nome!");
    // utilizamos o método focus() para colocar o cursor no campo em branco
    // e não deixamos que o formulário seja enviado utilizando return false
    document.form.Nome.focus()
    return false
  }
  var email = document.form.Email.value
  if (document.form.Email.value.indexOf('@', 0) == -1 || 
  document.form.Email.value.indexOf('.', 0) == -1)
  {
    alert("E-mail invalido!");
    document.form.Email.value = '';
    document.form.Email.focus();
    return false
  }
  var estado=document.form.Estado.value;
  if (estado=="")
  
  {
    alert("Entre com seu estado!")
    document.form.Estado.focus()
    return false
  }
}
//-->






