WordPress.org

Ready to get started?Download WordPress

Forums

wp nav menu adding a logout link by its self - How to remove? (8 posts)

  1. mxpimp47
    Member
    Posted 2 years ago #

    I am using wp nav menu for the menus on a site. And it is adding a logout menu link in the header nav all on its own. I dont have a custom link, or page with that name. It only does it when adding the pages for the woo-commerce shopping cart. Does anyone know why this would be happening? If you want to look go to staminaco dot com - i didnt want to put a link so you dont think I am trying to blow out the forum...

    Help trouble shooting this would be greatly appreciated!

    Thanks, Clayton

  2. esmi
    Forum Moderator
    Posted 2 years ago #

    Have you tried:

    - deactivating all plugins to see if this resolves the problem. If this works, re-activate the plugins one by one until you find the problematic plugin(s).

    - switching to the Twenty Eleven theme to rule out any theme-specific problems.

    - resetting the plugins folder by FTP or PhpMyAdmin. Sometimes, an apparently inactive plugin can still cause problems.

  3. SpankMarvin
    Member
    Posted 2 years ago #

    Almost certainly this has to be a filter added by the woo commerce plugin. Are you able to do a search of the plugin folder for the term

    add_filter('wp_nav_menu

    Note this is an incomplete line, but if this portion of text exists, you should be able to find the function attached to the hook, and then run a remove_filter to target and switch it off?

  4. mxpimp47
    Member
    Posted 2 years ago #

    I have a test site setup locally and so far I havent been able to recreate the problem on it yet. The only plugin that I dont have active on my local version is the disqus commenting system.

    I will try searching the plugin folder to see what I find....

    Thanks for your quick replies, really helps in a time of need!

  5. SpankMarvin
    Member
    Posted 2 years ago #

    I would still try looking for a filter as per the above. It might be in any plugin but that would certainly make sense.

  6. mxpimp47
    Member
    Posted 2 years ago #

    Ok I searched the plugin folder and found in the woocommerce_templates.php several lines but the one related to "nav" is this- add_filter('wp_list_pages', 'woocommerce_list_pages');

    what do you think from there?

  7. mxpimp47
    Member
    Posted 2 years ago #

    I found the issue, In the woocommerce settings there is an option to "add a logout link under my account" only problem was its not staying under my account, and when checked it actually doesnt create the page so you cant control it with the custom menu functionality. So I will let woo commerce know to make sure its not a silly bug...

    Thank you for your help! Great community - Clayton

  8. russellcunning
    Member
    Posted 2 years ago #

    I had the same problem - instead of displaying 'Home' on the menu, it displayed 'Log Out' - which did not function as a log-out link, but took me to Home. I disabled the plug-in 'theme-my-login', and everythihng was fine. I enabled the plug-in, and everything continues to be fine.

Topic Closed

This topic has been closed to new replies.

About this Topic

Tags

No tags yet.