function newComment(){ var dataID = $('#data_id').val(); if ($('#name').val() && $('#blurb').val()) { $('#commentSubmit').attr("disabled","disabled"); $('#commentSubmit').val('Espera por favor...'); $('#theseBlanks').hide(); $('#commentLoader').show(); $.post('/new_article_comment/',$('#commentForm').serialize(), function(txt) { $.get('/jax/get_new_comment/'+dataID+'/', function(txt){ $('#newComm').html(txt); $('#name').val(''); $('#commentEmail').val(''); $('#website').val(''); $('#blurb').val(''); $('#commentLoader').hide(); $('#commentSubmit').removeAttr("disabled"); $('#commentSubmit').val('Enviar'); $("#newComm").slideDown("slow"); }); }); } else { $('#theseBlanks').show(); } }