//Função para campo select automático

/*function campo_select_automatico(targ,selObj,restore)

{

eval(targ+".location='"+selObj.options[selObj.selectedIndex].value+"'");

if (restore) selObj.selectedIndex=0;

}*/

function menu_campo_select(pagina)

{

window.location = (pagina);

}

//Função para campo de pesquisa não preenchido

function verifica_formulario_pesquisa()

{

if (document.pesquisa.pesquisa.value  ==  "")

{

alert("Favor preencher o campo de pesquisa.");
document.pesquisa.pesquisa.focus();
return false;

}

}


//Função para marcar todos os checkbox de uma vez

function marcar_checkbox()

{

for (i=0;i<document.seleciona_itens.elements.length;i++)

{

if(document.seleciona_itens.elements[i].type  ==  "checkbox")

{

document.seleciona_itens.elements[i].checked=1;

}

}

}

function desmarcar_checkbox()

{

for (i=0;i<document.seleciona_itens.elements.length;i++)

{

if(document.seleciona_itens.elements[i].type  ==  "checkbox")

{

document.seleciona_itens.elements[i].checked=0;

}

}

}

//Função para menus em cascata no IE

startList = function()

{

if (document.all&&document.getElementById)

{

navRoot = document.getElementById("nav");

for (i=0; i<navRoot.childNodes.length; i++)

{

node = navRoot.childNodes[i];

if (node.nodeName=="LI")

{

node.onmouseover=function()

{

this.className+=" over";

}

node.onmouseout=function()

{

this.className=this.className.replace(" over", "");

}

}

}

}

}

window.onload=startList;