• Hi,

    So the plugin is working perfectly apart from one small issue. When I click something on the nav bar, it highlights the selected page but it also doesn’t unhighlight the previous page. If I click through every page then they will all end up highlighted.

    I have this code under ‘Click Code’

    // highlight the current menu item
    jQuery('ul.menu li').each(function() {
    	jQuery(this).removeClass('current-menu-item');
    });
    jQuery(thiss).parents('li').addClass('current-menu-item');
    
    jQuery(document).ready(function($) {
        var navigation;
    
        navigation = $('#primary-navigation');
    
        navigation.find('a').click(function() {
            navigation.removeClass('toggled-on');
        });
    });

    I’m using the standard twenty fourteen theme. Can anyone help?

    I have also tried

    // highlight the current menu item
    jQuery('ul.menu li').each(function() {
    	jQuery(this).removeClass('current-menu-item');
            jQuery(this).removeClass('current_page_item');
    });
    jQuery(thiss).parents('li').addClass('current_page_item');
    jQuery(thiss).parents('li').addClass('current-menu-item');

    https://www.ads-software.com/plugins/advanced-ajax-page-loader/

Viewing 2 replies - 1 through 2 (of 2 total)
  • Thread Starter MrPurplz

    (@mrpurplz)

    It seems it’s not firing the first time. The code to collapse the navigation bar only works the second time you click it. This may have something to do with this issue.

    I’ve tried disabling all plugins apart from this one but the same issue happens.

    Could really do with any insight!

    I have the same problem. Any word on a solution?

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘Navigation bar isn't unhighlighting’ is closed to new replies.