function blockContent(t){$(t).block({message:'',overlayCSS:{backgroundColor:"#fff",opacity:.7,cursor:"normal"},css:{border:0,padding:0,backgroundColor:"transparent"}})}$(document).delegate("form.ajaxForm","submit",(function(e){return methodType=$(this).attr("method"),"post"===methodType?($this=$(this),void 0!==$this.attr("data-alert")?alertDiv=$this.attr("data-alert"):(alertDiv="Msg"+this.id,0==$("#"+alertDiv).length&&$(this).prepend('
')),dataForm=new FormData(document.getElementById(this.id)),form_id=this.id,$(this).ajaxSubmit({url:$(this).attr("action"),method:"POST",dataType:"json",dataForm:dataForm,beforeSubmit:function(){$("#"+alertDiv).alertMsgClose()},afterSubmit:function(data){"error"===data.status?($("#"+alertDiv).alertMsg({msg:data.msg}),$("html,body").animate({scrollTop:$("#"+alertDiv).offset().top-60},"slow"),"function"==typeof captchareload&&captchareload(),1==data.reset&&$("#"+form_id)[0].reset(),data.script&&eval(data.script)):"success"===data.status?($("#"+alertDiv).alertMsg({msg:data.msg,type:"success"}),1==data.reset&&$("#"+form_id)[0].reset(),1==data.delete&&$("#"+form_id).remove(),data.script&&eval(data.script),$("html,body").animate({scrollTop:$("#"+alertDiv).offset().top-60},"slow")):"refresh"===data.status?window.location=location.href:"script"===data.status?(eval(data.msg),1==data.reset&&$("#"+form_id)[0].reset(),1==data.delete&&$("#"+form_id).remove()):"content"===data.status?($("#"+alertDiv).html(data.msg),1==data.reset&&$("#"+form_id)[0].reset(),1==data.delete&&$("#"+form_id).remove(),data.script&&eval(data.script),$("html,body").animate({scrollTop:$("#"+alertDiv).offset().top-60},"slow")):"redirect"===data.status&&(window.location.href=data.msg)},errorSubmit:function(){$("#"+alertDiv).alertMsg({msg:"Oops, we found an error! Please try again or refresh this page."}),$("html,body").animate({scrollTop:$("#"+alertDiv).offset().top-60},"slow")}})):loadPage($(this).attr("action"),$(this).serialize()),!1}));