Created
January 22, 2014 16:25
-
-
Save stebrech/8561841 to your computer and use it in GitHub Desktop.
Button um mit einer Animation an den Seitenanfang zu gelangen. Benötigt jQuery.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Back To Top | |
$('a.top').click(function(){ | |
$(document.body).animate({scrollTop : 0},800); | |
return false; | |
}); | |
//Create an anchor tag | |
<a class=”top” href=”#”>Back to top</a> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment