Team:StanfordBrownSpelman/jquery.scroll

From 2014.igem.org

Revision as of 18:44, 10 October 2014 by Raman2004 (Talk | contribs)

$(document).ready(function() {

$("#team").click(function() {

   $('body, html').animate({
       scrollTop: $("#teamNoodle").offset().top
   }, 700);
   e.preventDefault();
   });

$("#projects").click(function() {

   $('body, html').animate({
       scrollTop: $("#place").offset().top + 15
   }, 700);
   e.preventDefault();
   });
   

$("#wiki").click(function() {

   $('body, html').animate({
       scrollTop: $("#splash").offset().top
   }, 700);
   e.preventDefault();
   });
   

$("#contact").click(function() {

   $('body, html').animate({
       scrollTop: $("#precontact").offset().top
   }, 700);
   e.preventDefault();
   });
   

$("#pics").click(function() {

   $('body, html').animate({
       scrollTop: $("#images").offset().top
   }, 700);
   e.preventDefault();
   });

$("#intro").click(function() {

   $('body, html').animate({
       scrollTop: $("#int").offset().top
   }, 700);
   e.preventDefault();
   });
   

$("#data").click(function() {

   $('body, html').animate({
       scrollTop: $("#results").offset().top
   }, 700);
   e.preventDefault();
   });
   

$("#methods").click(function() {

   $('body, html').animate({
       scrollTop: $("#process").offset().top
   }, 700);
   e.preventDefault();
   });
   

$("#links").click(function() {

   $('body, html').animate({
       scrollTop: $("#references").offset().top
   }, 700);
   e.preventDefault();
   });

$("#top").click(function() {

   $('body, html').animate({
       scrollTop: $("#header").offset().top - $("#header").height()
   }, 700);
   e.preventDefault();
   });

$("#top2").click(function() {

   $('body, html').animate({
       scrollTop: '100px'});
   e.preventDefault();
   });

$("#contact").click(function() {

   $('body, html').animate({
       scrollTop: $("#test2").offset().top
   }, 700);
   e.preventDefault();  
   });
            });