I need Jquery's scrollTo function to work for this website: http://cinicraft.com/Silverman/index.html
I've tried the following
$(document).ready(function()
{
$("div.btnLp3").click(function(){
$('body,html').scrollTo('#target-examples', 800, {easing:'elasout'});
});
});
And I've tried this too:
$(document).ready(function()
{
$("div.btnLp3").click(function(){
$('html, body').animate({ scrollTop: $(window.location.hash).offset().top}, 1000);
});
});
I can't seem to get scrollTo
working at all. Does anyone have any ideas? Here's what I have imported:
<script src="http://ajax.googleapis.com/ajax/libs/jquery/1.10.2/jquery.min.js"> </script>
<script src="http://code.jquery.com/ui/1.10.3/jquery-ui.js"> </script>
Try this
$("#clickme").click(function() {
$('html, body').animate({
scrollTop: $("#wrap2").offset().top
}, 2000);
return false;
});