If you are creating a membership website, It is important to give different navigation links for logged In and Logged out users.
For example, when a user visits your website and is not logged in or registered, there will be a link on the navigation menu to login/register.
And After the user is logged in, the Login/register link will be hidden from the navigation and a Dashboard Link and other Logged In user links can show.
See the screenshot below of what I mean.
In this tutorial, I will show you How to Show Different Navigation Links to users. (also called If Menu)
How to Show Different Navigation Links to Users
First, you will need to use a membership plugin on your website to setup the login/register page & Dashboard/My Account Page.
To begin creating the If Navigation Menu,
1. Install & Activate this plugin: If Menu – Visibility control for Menu Items
2. After activating the plugin, go to Appearance >> Menu and from the Menu screen, you can select the Login/Register and Dashboard Page and add them to the menu structure.
3. Next, select the drop-down of the Dashboard & Login/Register Page and check the box “Enable visibility rules”.
Set the rule as “Show if is logged In” for the dashboard and “Hide if is logged In” for the Login/Register.
See the screenshot below.
4. Once you have selected the rules for the pages as seen above, don’t forget to save menu changes.
With this If Menu plugin, there are other visibility rules you can set for your page.
Note: Some membership plugin you use on your website may have visibility rules settings for your menu page.
Check first before you use this If Menu plugin.
That’s it for this tutorial.
If you like this article, you can subscribe to this blog via email, so you will get updates when there are new posts.