Helping you Build Your Own Social Network!

Faster, better and easier!

What's the link for a user gallery

(2 posts) (2 voices)
  • Started 1 year ago by koumanouye
  • Latest reply from Brajesh Singh

Tags:

No tags yet.


  1. I would like to be able to place a link to a logged-in user's gallery in my members sidebar. Is there an easy way to achieve this. Something like " bp_loggedin_user_ ".

    Not everyone understands that the word "gallery" is there to upload media components like pics and videos.

    I want the user to be able to go to the upload gallery page by clicking on a link or a picture.

    If possible let me know if I can also change the word "Gallery" in my nav bar

    Thanks much

    Posted 1 year ago #
  2. Hi, Sorry for this delayed response.

    Please use the language file to change the word gallery.

    For a logged in user gallery link, you may use the following code in your functions.php

    function temp_get_user_gallery_link($user_id){
    return bp_core_get_user_domain($user_id).BP_GALLERY_SLUG
    }

    and you can use it in code like

    global $bp;
    if(is_user_logged_in()):?>
    <a href="<?php echo temp_get_user_gallery_link($bp->loggedin_user->id);?>">My Gallery</a>
    <?php endif;?>

    Hope that helps.

    Posted 1 year ago #

Reply

You must log in to post.