replacing anchor text with jquery -
i have tried using html() , text() try change text of anchor - cant work :(
here fiddle show -
http://jsfiddle.net/kneidels/gzulh/
$('#contact-form-send').bind('click',function(e) { e.preventdefault(); $(".button").text('logging in...'); $("#mess").delay(2000).fadein(400); $("#mess").html('<p class="message">username/password not match. please contact our office assistance</p>'); $(".button").text("submit"); $("#mess").delay(2000).fadeout(400); });
thanks!
you using .delay()
lines following doesnt catch delay, need code when fadein done, write .fadein()
code :
$("#mess").delay(2000).fadein(400, function(){ $("#mess").html('<p class="message">username/password not match. please contact our office assistance</p>'); $(".button").text("submit"); $("#mess").delay(2000).fadeout(400); });
fiddle : http://jsfiddle.net/gzulh/3/
Comments
Post a Comment