Want an item in your website’s menu that will toggle between showing ‘Login’ or ‘Logout’ depending on whether the member is logged in or not?
There’s a really cool plugin that will let you do just that, and you don’t have to be using MemberPress either, it should work with just about any membership plugin or theme.
The plugin is called “Login or Logout Menu Item” – https://wordpress.org/plugins/login-or-logout-menu-item/
After installing the plugin on your site, head to your Dashboard -> Settings -> Login or Logout page.
Set some places you’d like the members to be redirected to when logging in, logging out, and where to find your actual login form (for MemberPress use its login page).
Save your settings, then head to your Appearance -> Menu’s page in your dashboard.
Open the menu you wish to show the Login/Logout menu item in, and do the following:
You’ll now have an automatic link in your menu that shows “Login” to visitors, and “Logout” to members who are already logged in. In fact, MemberPress uses this on their own site:
Pretty cool eh?
If you like that, you might also like my add-on that allows you to add your own menu items to MemberPress’ Account page menu. So check it out.