- This topic has 3 replies, 3 voices, and was last updated 10 years, 1 month ago by .
Viewing 4 posts - 1 through 4 (of 4 total)
Viewing 4 posts - 1 through 4 (of 4 total)
- You must be logged in to reply to this topic.
WordPress Membership Plugin
Simple Membership Plugin › Forums › Simple Membership Plugin › Keep full menu private until members are logged in
Tagged: alternate menu, login, member menu, members only
I’ve set up two login protected content pages. Instead of the way the menu currently works (where those pages can be clicked on and then the membership login prompts users to register) I’d like to have the menu that people see when they are not logged in be different from that of the logged in menu (the two pages that are members only would only be visible on the menu once the user has logged in via secret login page provided by the administrator). How can I do this?
I am not sure exactly what you are trying to achieve. Perhaps you might like to try a custom template in your theme. Can you also provide an example of what you are trying to achieve.
Thank you
I think I understand the task.
To create smth that wouldn’t be showed for non logged in members you should use this code:
<?php
if(!SwpmMemberUtils::is_member_logged_in()) {
echo '<a href="#">Example link</a>'; }
?>
And for users that logged in this code :
<?php
if(SwpmMemberUtils::is_member_logged_in()) {
echo '<a href="#">Example link</a>'; }
?>
It described in this article.
If you want to create different menus you should use these codes in your templates that way.
Does the above solution help you? Is your issue now resolved?