[Resolved] Menu item Forum thinks it is a child of item Blog

Home Forums Support [Resolved] Menu item Forum thinks it is a child of item Blog

Home Forums Support Menu item Forum thinks it is a child of item Blog

Viewing 6 posts - 1 through 6 (of 6 total)
  • Author
    Posts
  • #141561
    Dallas

    I am using GeneratePress with the GP-Premium add-on, BuddyPress and bbPress. Things are going along well, except when I select Forums. It goes to the Forum page, but the menu item Blog is highlighted instead of Forums. If I remove the Blog menu item, Forums still doesn’t highlight. Like I said, otherwise things are going well. Could someone take a look and let me know what I need to do to correct the problem? My web site is http://trilogusmediagroupco.ipage.com/edipros01/. Thanks in advance!

    #141569
    Dallas

    It looks like I’m not the only one having this problem:

    bbPress vs active menu item

    https://generatepress.com/forums/topic/bbpress-vs-active-menu-item/

    I tried the advice in this thread – but it is my primary menu that is having the issue, no secondary or side.

    #141607
    Tom
    Lead Developer
    Lead Developer

    This is an issue people keep on running into – in the near future I’ll be removing one of the classes that is causing this. It may cause some issues for a small percentage of people, but I think it will be better overall for everyone.

    One solution is to set up your forums on a regular page using the forums shortcode. Then set up a 301 redirect from the forums URL to your new page where you added the shortcode.

    That’s what I do on this site – it’s not ideal, but it should work until I make the change I mentioned above.

    Let me know if you have any questions or concerns ๐Ÿ™‚

    #141654
    Dallas

    I like the menu that comes with GeneratePress, but I was able to get around the issue by installing UberMenu. I think another menu plugin should work for just about anyone. I just happened to have UnberMenu already, and it no longer skips from the Forum to the Blog menu item. It’s still an issue for those using bbPress, but one I will do my best to get around. You did a great job with GeneratePress, and I hope you will continue to grow it. I am launching a professional association on it, and I know you will continue to make it a great option for WordPress users!

    #141715
    Tom
    Lead Developer
    Lead Developer

    Thanks for the update! Glad you found a solution ๐Ÿ™‚

    #141727
    Tom
    Lead Developer
    Lead Developer

    Just looking into this.

    Removing the styling for that class would make it so the Blog menu item was no longer highlighted when viewing a blog post in the blog.

    Some might not mind, but I think some would. People generally like knowing they’re still in the blog.

    I did some searching, and this is a known bbPress issue. The plugin (along with many other plugins using custom post types) adds the current_page_item class to the Blog menu item.

    Here’s a topic on it on the bbPress website:
    https://bbpress.org/forums/topic/viewing-forum-pages-makes-blog-menu-item-the-current_page_parent/

    And here’s the solution I wrote up: https://gist.github.com/generatepress/f5e4f6d1795cf6bb4c6a

    Adding PHP: https://generatepress.com/knowledgebase/adding-php-functions/

Viewing 6 posts - 1 through 6 (of 6 total)
  • You must be logged in to reply to this topic.