I’ve been trying to incorporate an auto scroll function on my website (live here). I want it to scroll to the content 6 seconds after load, but only if the user is on the very top of the page and hasn’t scrolled enough to uncover the #introduction element.
I have this code, which works, but I don’t want it to execute if the user has already scrolled by themself:
$('html,body').delay(6000).animate({
scrollTop: $('#introduction').offset().top
}, 1000);
I would also like it to happen with a type of ease-in-out, if possible.