function fixLinks() {

	if (document.all) {
	   var as = document.body.all.tags("A");
	} else {
	   var as = document.getElementsByTagName('a');
	}
	
	for(var i=0; i<as.length; i++) 
		if(as[i].getAttribute('alt') != null)
			if(as[i].getAttribute('href').indexOf("javascript") == 0){
				as[i].setAttribute('onmouseover','window.status=\''+as[i].getAttribute('alt')+'\';return true;');
			}
	return true;
}

function popup(width, height, url) {
	if(window.screen.width) {
		var left = (window.screen.width-width)/2;
		var top = (window.screen.height-height)/2;	
	}else{
		var left = (screen.width-width)/2;
		var top = (screen.height-height)/2;
	}
	
	var newwindow = window.open('/pages/'+url,'tryp_popup','height='+height+',width='+width+',resizable=no,scrollbars=yes,toolbar=no,status=yes, left='+left+', top='+top);
	
	if (window.focus) 
		newwindow.focus();
	
}

// popups para outros endereços que não no /pages/
function popup2(w, h, url) {
	var left = (screen.width-parseInt(w))/2;
	var top = (screen.height-parseInt(h)-100)/2;
	
	var newwindow = window.open (url,"tryp_popup","menubar=0,resizable=0,scrollbars=1,toolbar=0,status=1,width="+w+",height="+h+",top="+top+",left="+left+"");
	if (window.focus) newwindow.focus();	
}