Team:Grenoble-EMSE-LSU/Templates/Menu

From 2013.igem.org

(Difference between revisions)
Line 25: Line 25:
         <link rel="stylesheet" href="https://2013.igem.org/Team:Grenoble-EMSE-LSU/Design/Menu_Couleurs?action=raw&ctype=text/css" type="text/css"/>
         <link rel="stylesheet" href="https://2013.igem.org/Team:Grenoble-EMSE-LSU/Design/Menu_Couleurs?action=raw&ctype=text/css" type="text/css"/>
-
<!-- JQuery -->
 
-
<script src="http://ajax.googleapis.com/ajax/libs/jquery/1/jquery.js"></script>
 
-
 
-
<script type="text/javascript">
 
-
$(document).ready(function () { 
 
-
  var top = $('#haut').offset().top - parseFloat($('#haut').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
 
-
      $('#haut').addClass('fixed');
 
-
    } else {
 
-
      // otherwise remove it
 
-
      $('#haut').removeClass('fixed');
 
-
    }
 
-
  });
 
-
});
 
-
</script>
 
         <!--[if lt IE 9]>
         <!--[if lt IE 9]>

Revision as of 15:00, 14 August 2013

Grenoble-EMSE-LSU, iGEM


Retrieved from "http://2013.igem.org/Team:Grenoble-EMSE-LSU/Templates/Menu"