Template:Team:SCUT/Model/mainhead
From 2014.igem.org
(Difference between revisions)
Line 44: | Line 44: | ||
var element = $("#label_6"); | var element = $("#label_6"); | ||
scroll(element); | scroll(element); | ||
+ | } | ||
+ | </script> | ||
+ | |||
+ | <script type="text/javascript"> | ||
+ | function scroll(element){ | ||
+ | var eletop1 = element.offset().top; | ||
+ | $("body,html").animate({scrollTop:eletop1},600); | ||
+ | } | ||
+ | function scroll_a(element){ | ||
+ | var element = $("#index1"); | ||
+ | scroll(element); | ||
+ | } | ||
+ | function scroll_b(element){ | ||
+ | var element = $("#index2"); | ||
+ | scroll(element); | ||
+ | } | ||
+ | function scroll_c(element){ | ||
+ | var element = $("#index3"); | ||
+ | scroll(element); | ||
+ | } | ||
+ | function scroll_d(element){ | ||
+ | var element = $("#index4"); | ||
+ | scroll(element); | ||
+ | } | ||
+ | function scroll_e(element){ | ||
+ | var element = $("#index5"); | ||
+ | scroll(element); | ||
+ | } | ||
+ | function scroll_f(element){ | ||
+ | var element = $("#index6"); | ||
+ | scroll(element); | ||
+ | } | ||
+ | function scroll_g(element){ | ||
+ | var element = $("#index7"); | ||
+ | scroll(element); | ||
+ | } | ||
+ | function scroll_h(element){ | ||
+ | var element = $("#index8"); | ||
+ | scroll(element); | ||
} | } | ||
</script> | </script> | ||
</body> | </body> | ||
</html> | </html> |
Revision as of 02:31, 13 October 2014