I have a div that I want to ‘smart scroll’ up and down with a page. It starts off with position, fixed, and I use jQuery to dicide when to change that:
$('#el').css('position', 'static !important');
Works great in Safari + Chrome, but doesn’t work in Firefox. Any reason why this would be?
You don’t need !important when setting the style property of the element. It will already override any css selectors defined by default.