// Popup do detalhe dos forcados (elementos actuais ou todos elementos) 
var ventanacuadra ;
function ZPopup(imagem){    
if (ventanacuadra != null)
      if (!ventanacuadra.closed)
            ventanacuadra.close();
            ventanacuadra = my_window= window.open ('/' + imagem,'my_window','width=400,left=300,top = 200,height=180,status=yes');
            ventanacuadra.focus();
} 
var ventanacuadra1 ;
function ZPopup1(imagem){
if (ventanacuadra1 != null)
      if (!ventanacuadra1.closed)
            ventanacuadra1.close();
            ventanacuadra1 = my_window= window.open ('/' + imagem,'my_window','width=460,left=300,top = 200,height=210,status=yes');
            ventanacuadra1.focus();
}
var ventanacuadra2 ;
function ZGrande(imagem){
if (ventanacuadra2 != null)
      if (!ventanacuadra2.closed)
            ventanacuadra2.close();
            ventanacuadra2 = my_window= window.open ('/' + imagem,'my_window','width=440,left=300,top = 200,height=410,status=yes');
            ventanacuadra2.focus();
}
// Popup de validação  
function Zvalida(imagem){ 
my_window= window.open ('/' + imagem,'','width=500,left=300,top = 200,height=200'); 
}
function home () {
Home.style.color="chocolate";
Home.style.background="palegoldenrod";
Menu.style.color="chocolate";
}
function rhome () {
Home.style.color="tan";
Home.style.background="white";
Menu.style.color="tan";
}
// o browser e diferente do IE
function historia () {
Historia.style.color="chocolate";
Historia.style.background="palegoldenrod";
Menu11.style.color="chocolate";
}
function rhistoria () {
Historia.style.color="tan";
Historia.style.background="white";
Menu11.style.color="tan";
}
// o browser e diferente do IE
function elementos () {
Elementos_a.style.color="chocolate";
Elementos_a.style.background="palegoldenrod";
Menu9.style.color="chocolate";
}
function relementos () {
Elementos_a.style.color="tan";
Elementos_a.style.background="white";
Menu9.style.color="tan";
}
//******************
// o browser e diferente do IE
function elementost () {
Elementos_t.style.color="chocolate";
Elementos_t.style.background="palegoldenrod";
Menu10.style.color="chocolate";
}
function relementost () {
Elementos_t.style.color="tan";
Elementos_t.style.background="white";
Menu10.style.color="tan";
}
//************************
// o browser e diferente do IE
function agenda () {
Agenda.style.color="chocolate";
Agenda.style.background="palegoldenrod";
Menu12.style.color="chocolate";
}
function ragenda () {
Agenda.style.color="tan";
Agenda.style.background="white";
Menu12.style.color="tan";
}
//************************
function moita () {
Moita.style.color="chocolate";
Moita.style.background="palegoldenrod";
Menu2.style.color="chocolate";
}
function rmoita () {
Moita.style.color="tan";
Moita.style.background="white";
Menu2.style.color="tan";
}

function galeria () {
Galeria.style.color="chocolate";
Galeria.style.background="palegoldenrod";
Menu4.style.color="chocolate";

}
function rgaleria () {
Galeria.style.color="tan";
Galeria.style.background="white";
Menu4.style.color="tan";
}

function mensagens () {
Mensagens.style.color="chocolate";
Mensagens.style.background="palegoldenrod";
Menu6.style.color="chocolate";
}
function rmensagens () {
Mensagens.style.color="tan";
Mensagens.style.background="white";
Menu6.style.color="tan";
}
function entrevista () {
Entrevista.style.color="chocolate";
Entrevista.style.background="palegoldenrod";
Menu7.style.color="chocolate";
}
function rentrevista () {
Entrevista.style.color="tan";
Entrevista.style.background="white";
Menu7.style.color="tan";
}
function contactos () {
Contactos.style.color="chocolate";
Contactos.style.background="palegoldenrod";
Menu8.style.color="chocolate";
}
function rcontactos () {
Contactos.style.color="tan";
Contactos.style.background="white";
Menu8.style.color="tan";
}
function paginap () {
pagp.style.color="brown";
}
function rpaginap () {
pagp.style.color="#777";
}
function paginaa () {
paga.style.color="brown";
}
function rpaginaa () {
paga.style.color="#777";
}
function retornoa () {
retorno.style.color="brown";
}
function rretornoa () {
retorno.style.color="silver";
}
function retorno2a () {
retorno2.style.color="brown";
}
function rretorno2a () {
retorno2.style.color="silver";
}
function mostra(w,h,nav,loc,sts,menu,scroll,resize,name,url) {
 var windowProperties=''; if(nav==false) windowProperties+='toolbar=no,'; else
 windowProperties+='toolbar=yes,'; if(loc==false) windowProperties+='location=no,'; 
 else windowProperties+='location=yes,'; if(sts==false) windowProperties+='status=no,';
 else windowProperties+='status=yes,'; if(menu==false) windowProperties+='menubar=no,';
 else windowProperties+='menubar=yes,'; if(scroll==false) windowProperties+='scrollbars=no,';
 else windowProperties+='scrollbars=yes,'; if(resize==false) windowProperties+='resizable=no,';
 else windowProperties+='resizable=yes,'; if(w!="") windowProperties+='width='+w+',';
 if(h!="") windowProperties+='height='+h; if(windowProperties!="") { 
  if( windowProperties.charAt(windowProperties.length-1)==',') 
   windowProperties=windowProperties.substring(0,windowProperties.length-1); } 
 window.open(url,name,windowProperties);
}
// funcao que mostra o submenu ou esconde o submenu 
function startList () {
 if (document.all&&document.getElementById) {
   navRoot = document.getElementById("nav");
   navmenu = document.getElementById("Elementos_a");
   navmenu1 = document.getElementById("Elementos_t");
   navmenu2 = document.getElementById("historia");
   navmenu3 = document.getElementById("agenda");
   
     for (i=0; i<navRoot.childNodes.length; i++) {
       node = navRoot.childNodes[i];
         if (node.nodeName=="LI") {
           node.onmouseover=function() {
             this.className+="hover";
             navmenu.style.color="chocolate";
             navmenu.style.background="palegoldenrod";
             navmenu1.style.color="chocolate";
             navmenu1.style.background="palegoldenrod";
             navmenu2.style.color="chocolate";
             navmenu2.style.background="palegoldenrod";
             navmenu3.style.color="chocolate";
             navmenu3.style.background="palegoldenrod";
             }
              node.onmouseout=function() {  
                this.className=this.className.replace("hover", "");
                navmenu.style.color="tan";
                navmenu.style.background="white";
                navmenu1.style.color="tan";
                navmenu1.style.background="white";
                navmenu2.style.color="tan";
                navmenu2.style.background="white";
                navmenu3.style.color="tan";
                navmenu3.style.background="white";
              }
          }
      }
   }
}
// alimenta a variavel do mes 
today = new Date()
var curr_date = today.getDate();
var curr_month = today.getMonth();
var curr_year = today.getFullYear();

if (curr_month == 0) {
	var descmes = 'Janeiro';
}
else if (curr_month == 1) {
	var descmes = 'Fevereiro';
}
else if (curr_month == 2) {
	var descmes = 'Março';
}
else if (curr_month == 3) {
	var descmes = 'Abril';
}
else if (curr_month == 4) {
	var descmes = 'Maio';
}	
else if (curr_month == 5) {
	var descmes = 'Junho';
}	
else if (curr_month == 6) {
	var descmes = 'Julho';
}	
else if (curr_month == 7) {
	var descmes = 'Agosto';
}	
else if (curr_month == 8) {
	var descmes = 'Setembro';
}	
else if (curr_month == 9) {
	var descmes = 'Outubro';
}	
else if (curr_month == 10) {
	var descmes = 'Novembro';
}	
else if (curr_month == 11) {
	var descmes = 'Dezembro';
}	
