Difference between revisions of "Template:Freiburg/MenubarTest"
Line 496: | Line 496: | ||
$("#header").css('width','100%'); | $("#header").css('width','100%'); | ||
$("#page-content").css('margin-top', '100px'); | $("#page-content").css('margin-top', '100px'); | ||
− | + | ||
+ | |||
$(window).scroll(function (event) { | $(window).scroll(function (event) { | ||
var y = $(this).scrollTop(); | var y = $(this).scrollTop(); | ||
− | + | console.log(y); | |
if(y>61){ | if(y>61){ | ||
− | |||
$("#header").css('position','fixed'); | $("#header").css('position','fixed'); | ||
Line 511: | Line 511: | ||
$("#runningchip-back").css('display','none'); | $("#runningchip-back").css('display','none'); | ||
$("#navtext").css('margin-top','-20px'); | $("#navtext").css('margin-top','-20px'); | ||
− | |||
− | |||
}else{ | }else{ | ||
− | |||
// $("#header").removeAttr('style'); | // $("#header").removeAttr('style'); | ||
Line 522: | Line 519: | ||
$("#runningchip-back").removeAttr('style'); | $("#runningchip-back").removeAttr('style'); | ||
$("#navtext").removeAttr('style'); | $("#navtext").removeAttr('style'); | ||
− | |||
} | } | ||
Revision as of 15:08, 10 September 2015