I used the class “current-menu-item” to style the navigation button differently for the current page.
I used PageBuilder on the home page, with a Post Loop widget to display recent posts from a custom post type.
Now both the home button AND the navigation button for this custom post type are being given the class “current-menu-item” and show the different styling. And idea how I can stop the custom post loop from taking on “current-menu-item” on the home page? (Without affecting the menu behavior on the custom post type’s archive page.)
Hi. Perhaps try temporarily removing your custom CSS and rather using the current page item options under Appearance > Customize > Menu as I don’t think those will clash with the Post Loop widget. For those options to work in the Customizer you must have a custom menu saved under Appearance > Menus and that menu must be assigned to the primary menu position.
Thank you, I’ll look into that as well. I ended up using jQuery removeClass to target the button on only the home page.
Super, glad you found a solution.
Another fix would have been to limit your CSS to #masthead .site-navigation.
All the best.