For some reason, once I added the following HTML code from Whova on the page, it made the nav bar scroll:
<div><div title="Whova event and conference app" id="whova-exhibitorwidget"><p id="whova-loading">Loading...</p></div><script src="https://whova.com/static/xems/js/embed/whova-exhibitor-widget.js?eid=tmcca_201811&host=https://whova.com" type="text/javascript" id="embeded-exhibitor-script"></script><div id="whova-wrap">Powered By <a class="brandlink" target="_blank" href="https://www.whova.com"><b>Whova - Best Event App</b></a><div id="whova-mgm"><a href="https://whova.com/whova-event-app/" id="whova-emslink" target="_blank">Whova event and conference app</a></div></div></div>
What portion of this code to I need to alter or what do I need to do in order to get the nav bar to function properly? It only happens on this page. The rest are fine.
$(document).ready(function() {
$(window).scroll(function () {
//if you hard code, then use console [Showbox App](https://show-box.pro/)
//.log to determine when you want the
//nav bar to stick.
console.log($(window).scrollTop())
if ($(window).scrollTop() > 280) {
$('#nav_bar').addClass('navbar-fixed');
}
if ($(window).scrollTop() < 281) {
$('#nav_bar').removeClass('navbar-fixed');
}
});
});
$(window).scroll(function () {
//if you hard code, then use console showbox app
//.log to determine when you want the
//nav bar to stick.
console.log($(window).scrollTop())
if ($(window).scrollTop() > 280) {
$(‘#nav_bar’).addClass(‘navbar-fixed’);
}
if ($(window).scrollTop() < 281) {
$(‘#nav_bar’).removeClass(‘navbar-fixed’);
}
});
});
html, body {
height: 4000px;
}