[Plugin: Alkivia Open Community] Alkivia User profile information access control
-
Hey,
I’m running a highly customized Alkivia user profile template to display all my users and all of their profile information. I’ve added a lot of extra user info to both their WP user profile and their Alkivia user profile. I’m using a plugin called “Register Plus” to store custom, extra user info in the WP database user_meta table, then displaying that info on my Alkivia user profiles pages. Trouble is, I only want to display some of it for public (non-logged in) users, and save the rest for logged in members. I can’t figure out how to do this. I’ve successfully done something similar with the navigation sidebar by using this statement:
<?php if ( $user_ID ) : ?> <a href="<?php bloginfo('wpurl') ?>/email-members">Email Members</a> <?php endif; ?>
So only logged in members will see this. However, I can’t figure out how to do the same thing for the following code from my Alkivia profile page template:
<?php if ( ! empty($user->phone) ) { _e('Phone: ', $text_domain); echo $user->phone; ?> <?php } ?>
In this code I check for the users phone number and only display it if they have one listed in their profile. Otherwise I don’t even display “phone:” But when I mess around with adding
<?php if ( $user_ID ) : ?>
anywhere in that statement nothing works. I want the alkivia profile to be public, but just to hide certain info from non-logged in members through some sort of if statement just like I did for the site navigation. Does anyone know enough PHP and/or Alkivia to help me out with this?Thanks,
Daniel
- The topic ‘[Plugin: Alkivia Open Community] Alkivia User profile information access control’ is closed to new replies.