I have created a drop down menu that I have used on many sites. For some reason in this application (http://quaker.wpengine.com/) the menu flickers and is mispositioned in both Firefox and IE8-10. It works fine in Chrome and Safari. Any idea why this might be happening? I think it is a CSS issue, but can't figure it out for the life of me.
Thanks for the help!
Here is the JS I am using on the menu:
//Add necessary classes to navigation
$('ul.level-1 > li > ul').addClass('level-2');
$('ul.level-1 ul > li ul').addClass('level-3');
$('li:has(> ul)').addClass('has-subnav');
// Mobile Navigation
$('body').addClass('js');
var $menu = $('#menu'),
$menulink = $('.menu-link'),
$menuTrigger = $('.has-subnav > a');
$menulink.click(function(e) {
//e.preventDefault();
$menulink.toggleClass('active');
$menu.toggleClass('active');
});
$menuTrigger.click(function(e) {
if ( $(window).width() < 768) {
e.preventDefault();
}
var $this = $(this);
$this.toggleClass('active').next('ul').toggleClass('active');
});
//Remove active class on desktop version
$('ul.level-1 > li').hover(
function () {
$('ul.level-1 > li').removeClass('active');
var $this = $(this);
if( $this.children('ul.level-2').css('display') != 'none' ) {
$this.addClass('active');
} else {
$this.removeClass('active');
}
},
function () {
var $this = $(this);
if( $this.children('ul.level-2').css('display') != 'none' ) {
$this.addClass('active');
} else {
$this.removeClass('active');
}
}
);