Using http://stickyjs.com/
I am trying to make my menu stay at the top of the browser except on mobile devices (i.e #header below 400px), this is my code which isn't throwing up any errors when i check is JSHint, but at the same time isn't working
-
$(document).ready(function () { -
if ($('#header').width() > 400) { -
$("#menu").sticky({ topSpacing: 0 }); -
} -
}); -
$(document).ready(main);
Could really use some help if anyone has an idea?