Team:Grenoble-EMSE-LSU/Menu

From 2013.igem.org

(Difference between revisions)
Line 1: Line 1:
<html>
<html>
-
 
-
<!-- JQuery -->
 
-
 
-
<!--<script src="http://ajax.googleapis.com/ajax/libs/jquery/1/jquery.js"></script>
 
-
 
-
<script type="text/javascript">
 
-
$(document).ready(function () { 
 
-
  var top = $('#nav').offset().top - parseFloat($('#nav').css('marginTop').replace(/auto/, 0));
 
-
  $(window).scroll(function (event) {
 
-
    // what the y position of the scroll is
 
-
    var y = $(this).scrollTop();
 
-
 
 
-
    // whether that's below the form
 
-
    if (y >= top) {
 
-
      // if so, ad the fixed class
 
-
      $('#nav').addClass('fixed');
 
-
    } else {
 
-
      // otherwise remove it
 
-
      $('#nav').removeClass('fixed');
 
-
    }
 
-
  });
 
-
});
 
-
</script>-->
 
<nav id="nav">
<nav id="nav">
Line 91: Line 68:
            
            
       </nav>
       </nav>
 +
 +
        <script src="http://ajax.googleapis.com/ajax/libs/jquery/1/jquery.js"></script>
 +
        <script src="https://2013.igem.org/Team:Grenoble-EMSE-LSU/Design/js"></script>
</html>
</html>

Revision as of 12:52, 20 August 2013