Template:Team:Calgary/Test
From 2013.igem.org
(Difference between revisions)
Line 3: | Line 3: | ||
<script> | <script> | ||
$(document).ready(function() { | $(document).ready(function() { | ||
- | |||
$('#Banner').css('display', 'block'); | $('#Banner').css('display', 'block'); | ||
$('#Page').css({'position' : 'relative', top : '120px'}); | $('#Page').css({'position' : 'relative', top : '120px'}); | ||
Line 17: | Line 16: | ||
$(window).scroll(function() { | $(window).scroll(function() { | ||
- | if(window.pageYOffset < 100) | + | if(window.pageYOffset < 100) { |
$('#TopBar').css('position', 'static'); | $('#TopBar').css('position', 'static'); | ||
$('#Content').css('top', '1px'); | $('#Content').css('top', '1px'); | ||
- | else | + | } |
+ | else { | ||
$('#TopBar').css('position', 'fixed'); | $('#TopBar').css('position', 'fixed'); | ||
$('#Content').css('top', '180px'); | $('#Content').css('top', '180px'); | ||
+ | } | ||
}); | }); | ||
}); | }); | ||
</script> | </script> | ||
</html> | </html> |
Revision as of 04:13, 23 September 2013