Skip to content

Instantly share code, notes, and snippets.

Created January 7, 2013 19:47
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save anonymous/4477799 to your computer and use it in GitHub Desktop.
Save anonymous/4477799 to your computer and use it in GitHub Desktop.
Create a Smooth Scrolling Effect for your Page Sections in Breezi
<!-- smooth scrolling script -->
<script>
$(function () {
$('a[href^="#"]').click(function(event) {
var id = $(this).attr("href");
var offset = 20;
var target = $(id).offset().top - offset;
$('html, body').animate({scrollTop:target}, 500);
event.preventDefault();
});
});
</script>
<!-- end smooth scrolling script -->
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment