	function abreFecha(x){
		var div = document.getElementById(x + '_txt');
		var bt	= document.getElementById(x + '_bt');

		if (div.style.display == 'none'){
			div.style.display = '';
			bt.src = 'img/bt_seta_up.gif';
		}else{
			div.style.display = 'none';
			bt.src = 'img/bt_seta_down.gif';
		}
		return false;
	}
	
	
	
	
	
////////////////////////////////////////////////////////////////
//// bookmark
////////////////////////////////////////////////////////////////
	function favoritos(endereco,titulo) {
		var url      = endereco;
		var title    = titulo;
		
		//alert(url +"_|_"+ title);
		if (window.sidebar) window.sidebar.addPanel(title, url,"");
		
		else if(window.opera && window.print){
			  var mbm = document.createElement('a');
			  mbm.setAttribute('rel','sidebar');
			  mbm.setAttribute('href',url);
			  mbm.setAttribute('title',title);
			  mbm.click();
		  }
		
		
		
		  else if(document.all){window.external.AddFavorite(url, title);}
	}
	/*
	///// EXEMPLO//////
	function addFav(){
		var url      = "http://www.emfaseteste.blogspot.com";
		var title    = "emfaseteste.blogspot - Não tenho certeza, mas é web e informatica";
		if (window.sidebar) window.sidebar.addPanel(title, url,"");
		
		else if(window.opera && window.print){
			  var mbm = document.createElement('a');
			  mbm.setAttribute('rel','sidebar');
			  mbm.setAttribute('href',url);
			  mbm.setAttribute('title',title);
			  mbm.click();
		  }
		
		
		
		  else if(document.all){window.external.AddFavorite(url, title);}
	}
	*/







////////////////////////////////////////////////////////////////
///	POP-UP
////////////////////////////////////////////////////////////////
function abrir(pagina,largura,altura) {
	
	//pega a resolução do visitante
	w = screen.width;
	h = screen.height;
	
	//divide a resolução por 2, obtendo o centro do monitor
	meio_w = w/2;
	meio_h = h/2;
	
	//diminui o valor da metade da resolução pelo tamanho da janela, fazendo com q ela fique centralizada
	altura2 = altura/2;
	largura2 = largura/2;
	meio1 = meio_h-altura2;
	meio2 = meio_w-largura2;
	
	//abre a nova janela, já com a sua devida posição
	window.open(pagina,'','height=' + altura + ', width=' + largura + ', top='+meio1+', left='+meio2+'');
}




