I'm working on a website and I'm trying to make every measurement to be in em's, but but the script I repurposed from an old project I can't seem to get working with em's, it only seems to work with pixels.
$(window).scroll(function(){
$("#nav").css("top",Math.max(0,96-$(this).scrollTop()));
});
Here's a demo of what it does:
If anyone can help and show me what I need to do it would be greatly appreciated!