-
bp-help replied to the topic Get Logged-In User Profile Link URL? in the forum How-to & Troubleshooting 9 years, 10 months ago
@ctyldsley
Use the below code if you only want the image linking to their profile for logged in users.
if ( is_user_logged_in() ) {
<a href="<?php echo bp_loggedin_user_domain(); ?>"><img src="<?php bloginfo('url'); ?>/wp-content/uploads/2015/01/ManageProfile.png"></a>
}
-
bp-help replied to the topic Get Logged-In User Profile Link URL? in the forum How-to & Troubleshooting 9 years, 10 months ago
@ctyldsley
I am assuming you will be be putting the image that connects each user to their profile in a template although I am not sure which one you would want to place it in but something like this should work:
[Read more]
<a href="<?php echo bp_loggedin_user_domain(); ?>"><img src="<?php bloginfo('url');… -
Henry Wright replied to the topic Get Logged-In User Profile Link URL? in the forum How-to & Troubleshooting 9 years, 10 months ago
Hi @ctyldsley
echo '/hbcmembers/' . bp_core_get_username( get_current_user_id() ) . '/profile/';
Will output /hbcmembers/logged-in-username/profile/
Hope that helps.
@ctyldsley
Active 9 years, 10 months ago