auto back to top in jquery
Does anyone there have any way that I can auto make the page back to top without refresh the page after a submit process is completed in开发者_如何学JAVA jquery?
you can use this
$("#divid").scrollTop(0);
if you wnat the body do this
$("html,body").scrollTop(0);
made a sample here, scroll down there is a scroll top text ,click that
http://jsfiddle.net/D5x7F/
window.location='#'
Now it's not jquery but it's easy javascript and you can call this after your jquery is done.
精彩评论