Hide the main navigation from non-logged in users?????
-
Hiya,
I have searched the forums to something I am trying to do and haven’t found a solution that works. We’re trying to hide the main navigation from non-logged in users. Now, we don’t have the home page on the same domain. In fact we have it on a sub domain. However when the user visits the registration page they can gain access to the whole site. We need to remove the log in function and the main navigation from this page.(home, blog, members, etc…). We have tried a lot of solutions but they don’t work. Any ideas?
-
take a look here
that is the home page of a wpmu/buddypress install, we are just using a different template, and setting the ‘reading’ option to have the home page a static page
I wish it was that simple but, it doesn’t work like that for our site. Our main page is located on a subdomain outside of WordPress it self. When people refer to our main domain then they are redirected to home.subdomain.com. From there they can log in. When new visitors try to register they can gain access to the entire site through this page.
well there are members plugins that wont allow the nav to show if the member isnt logged in, one is user access manager – you can specify pages to not show all together, in nav as well – would this work?
if (is_user_logged_in()) {
// Do stuff
} else {
// Do other stuff
}We have decided to move all of the navigation to the admin bar. We are working on adding the following code to the bp-core-admin.php.
//*********Help*********//
function my_help_link(){ ?> Help <ul class=”your-ul-list-css-classname”> Help 1 <li class=”alt”>Help 2 Help 3 <li class=”alt”>Help 4 Help 5 <?php } add_action( ‘bp_adminbar_menus’, ‘my_help_link’, 3 );
The above code is an example from this site. However when we try to add the below code into the above code we get errors.
if (is_user_logged_in()) { // Do stuff } else { // Do other stuff }
So we need to figure out how to properly write the code. Then we can move all main navigation links to the admin bar bu using the same function. I’ll keep working until I get it right. It just makes better sense to keep all links in one area.
I am sorry the bp-core-adminbar.php
Please this is my first experience with WordPress and buddypress. I have installed wordpress Mu/buddypress successfully, I want to have a site where the main page will be used as an introduction to my social networking site, as well as the platform for login, and the second page to be the main social networking page… i have installed some customed made theme for the purpose of the Social.n/w.. but the whole thing is confusing me. PLEASE… i will be grateful if any one can give me step by step hint on how to go about this…….
….placing one theme as main page in subdomain and the other in main domain is…? Please Help…
- The topic ‘Hide the main navigation from non-logged in users?????’ is closed to new replies.