I\'m trying to animate while scrolling but no luck with my code...
I have this jquery
$(window).scrollTop(200);
Now wanted to give
DEMO
function scrollmetop(dest){ var stop = $(dest).offset().top; var delay = 1000; $('body,html').animate({scrollTop: stop}, delay); return false; } scrollmetop('#test'); target object