// JavaScript Document

function Trim(str){

	if(typeof(str) != "string") return "";
	
	var regexp = /[\t\r\n ]+$/; 
	str = str.replace(regexp, "");
	
	regexp = /^[\t\r\n ]+/; 
	str = str.replace(regexp, "");
	
	return str;

}


function ehVazio(valor){
	
	valor = Trim(valor);
	
	if(valor == ''){
		return true;
	}
	else{
		return false;
	}

}

