function trim(str){
	return str.replace(/^\s+|\s+$/g,"");
}
function str_replace(str, find, replace) {
	return str.split(find).join(replace);
}
function resizeWords(t){
	var c = $('conteudo_resize_words');
	var e = c.getElements('*');
	var s = 0;
	var x = 2;
	for(i=0;i<e.length;i++){
		s = Number(str_replace(e[i].getStyle('font-size'),'px',''));
		switch(t){
			case '-':
				if((s-x)>8){
					s -= x;
				}
			break;
			case '+':
				if((s+x)<22){
					s += x;
				}
			break;
		}
		e[i].setStyle('font-size',s+'px');
	}
}
function showMapGoogle(){
	var iframe = '<iframe class="iframe_mapa" allowtransparency="true" width="100%" height="400" frameborder="0" scrolling="no" marginheight="0" marginwidth="0" src="http://www.google.com.br/maps?f=q&amp;hl=pt-BR&amp;geocode=&amp;q=Av.+Paulista,+1313+-+8%C2%BA+andar+%E2%80%93+Cj.+809+S%C3%A3o+Paulo+-+SP+-+Brasil&amp;sll=-14.179186,-50.449219&amp;sspn=101.745072,158.203125&amp;ie=UTF8&amp;z=14&amp;g=Av.+Paulista,+1313+-+8%C2%BA+andar+%E2%80%93+Cj.+809+S%C3%A3o+Paulo+-+SP+-+Brasil&amp;iwloc=addr&amp;ll=-23.553602,-46.650181&amp;output=embed&amp;s=AARTsJojidIFzJ415Dkf566FEQbu89NvGw"></iframe>';
	if($('contato_mapa').getStyle('display')=='none'){
		$('contato_mapa').setStyle('display','block');
		$('contato_conteudo').setStyle('display','none');
		$('iframe_mapa').setProperty('html',iframe);
	}else{
		$('contato_mapa').setStyle('display','none');
		$('contato_conteudo').setStyle('display','block');
		$('iframe_mapa').erase('html');
	}
}
function openCloseBox(id,idd){
	var box = $(id);
	if(box.getStyle('display')=='none'){
		box.setStyle('display','block');
		if(idd!=''){
			$(idd).setStyle('display','none');
		}
	}else{
		box.setStyle('display','none');
		if(idd!=''){
			$(idd).setStyle('display','block');
		}
	}
}
/*
function clear_input(id){
	id.setProperty('value','');
}
function test_inputs_form(){
	//nome
	var p_nome = 'seu nome';
	var nome = $('input_nome');
	var nome_value = trim(nome.getProperty('value'));
	if(nome_value.length<=0){
		nome.setProperty('value',p_nome);
	}
	//e-mail
	var p_mail = 'seu e-mail';
	var re = /^[\w!#$%&'*+\/=?^`{|}~-]+(\.[\w!#$%&'*+\/=?^`{|}~-]+)*@(([\w-]+\.)+[A-Za-z]{2,6}|\[\d{1,3}(\.\d{1,3}){3}\])$/;
	var mail = $('input_mail');
	var mail_value = trim(mail.getProperty('value'));
	if(!re.test(mail_value)){
		mail.setProperty('value',p_mail);
	}
}
*/