/* ############################# # FUNÇÕES DE FORMULARIO ############################# */ function Invalido(CAMPO, CLASSE) { CAMPO.className = CLASSE; } function Valido(CAMPO, CLASSE) { CAMPO.className = CLASSE; return true; } function SupEnter(event) { var keyCode = event.keyCode ? event.keyCode : event.which ? event.which : event.charCode; if ( keyCode == 13 ) { return false; } else { return true; } } function trim(stringToTrim) { return stringToTrim.replace(/^\s+|\s+$/g,""); } function ltrim(stringToTrim) { return stringToTrim.replace(/^\s+/,""); } function rtrim(stringToTrim) { return stringToTrim.replace(/\s+$/,""); } function supertrim(StringToTrim){ return( StringToTrim.replace( /^\s+|\s+$/gi, "" ).replace( /\s{2,}/gi, " " ) ); } function get(id) { return(document.getElementById(id)); } function FechaDHtml() { document.getElementById("PubDHtml").style.display = "none"; } function MostraDHtml() { document.getElementById("PubDHtml").style.display = "block"; } function MM_preloadImages() { /* v3.0 */ var d=document; if(d.images){ if(!d.MM_p) d.MM_p=new Array(); var i,j=d.MM_p.length,a=MM_preloadImages.arguments; for(i=0; i
[x] Fechar
'); /* Pub */ $("#pub").css({'width':w+20,'height':h+20}); $("#pub #pub-banner").html(code); /* Mascara */ var maskHeight = $(document).height(); var maskWidth = $(window).width(); $('#mask').css({'width':maskWidth,'height':maskHeight}); var y=0; if (self.pageYOffset) { y = self.pageYOffset; } else if (document.documentElement && document.documentElement.scrollTop) { y = document.documentElement.scrollTop; } else if (document.body) { y = document.body.clientHeight; } var winH = y; var winW = $(window).width(); var Hfinal = ((($(window).height()) - $("#pub").height())/2); $("#pub").css('top', Hfinal); $("#pub").css('left', winW/2-$("#pub").width()/2); $('#mask').fadeTo("fast",0.5, function() { $("#pub").fadeIn(1000); }); $(window).resize(function () { var maskHeight = $(document).height(); var maskWidth = $(window).width(); $('#mask').css({'width':maskWidth,'height':maskHeight}); var winH = $(window).height(); var winW = $(window).width(); $("#pub").css('top', winH/2-$("#pub").height()/2); $("#pub").css('left', winW/2-$("#pub").width()/2); }); $('#pub-close a').click(function () { $("#mask").hide(); $('#pub').hide().remove(); }); }); }; MM_preloadImages('http://www.novolarimoveis.com/imagens/loading.gif');