Team:Cornell/sandbox/general
From 2013.igem.org
(Difference between revisions)
(Created page with "{{:Team:Cornell/sandbox/header}} <html> <body> <div class="title"> </div> <div class="navbar" style="position: relative; z-index: 20; margin-top: -29px; font-weight:...") |
|||
Line 1: | Line 1: | ||
{{:Team:Cornell/sandbox/header}} | {{:Team:Cornell/sandbox/header}} | ||
<html> | <html> | ||
+ | <head> | ||
+ | <script type="text/javascript"> | ||
+ | $(document).ready(function() { | ||
+ | //change navbar position when scrolling | ||
+ | if (window.pageYOffset < 160) { | ||
+ | $(".navbar").css('position', 'static'); | ||
+ | } | ||
+ | else { | ||
+ | $(".navbar").css('position', 'fixed'); | ||
+ | } | ||
+ | |||
+ | $(window).scroll(function() { | ||
+ | if (window.pageYOffset < 160) { | ||
+ | $(".navbar").css('position', 'static'); | ||
+ | } | ||
+ | else { | ||
+ | $(".navbar").css('position', 'fixed'); | ||
+ | } | ||
+ | }); | ||
+ | }); | ||
+ | </script> | ||
+ | </head> | ||
<body> | <body> | ||
<div class="title"> | <div class="title"> |
Revision as of 18:02, 26 July 2014