Skip to:
Content
Pages
Categories
Search
Top
Bottom

Change first page shown for user profile


  • raoul140
    Participant

    @raoul140

    Hi,

    Can we modify the page that opens when we click on a profile name (for exemple, when we click on the name of an user who commented on a post). At the moment, the link opens the “Activity” page of that user. I would like it to show the “Profile” page of that user instead. Any easy solution?

    I am using BuddyPress 1.6.1 as part of a template I bought from Themeforest, template is called “reviewit”. ReviewIt is built as a BuddyPress/bbPress theme as far as i know.

Viewing 4 replies - 1 through 4 (of 4 total)

  • sullyllus
    Participant

    @sullyllus

    I was just abut to post this exact same question. Anyone out there able to help us out?

    I want my user profiles (front end view) to open up a custom page. If this is not an option then I would like the standard “Profile” page to show.

    TIA BuddyPress gurus!


    @mercime
    Keymaster

    @mercime

    To start off, you’d have to change template tags e.g. change default link to Member Activity Page to Member Profile page

    change
    <a href="<?php bp_member_permalink(); ?>"><?php bp_member_avatar(); ?></a>
    to
    <a href=”<?php echo bp_loggedin_user_domain(); ?>”><?php bp_member_avatar(); ?></a>
    
    change
    <a href="<?php bp_member_permalink(); ?>"><?php bp_member_name(); ?></a>
    to
    <a href=”<?php echo bp_loggedin_user_domain(); ?>”><?php bp_member_name(); ?></a>

    raoul140
    Participant

    @raoul140

    Hi, thank you for quick answer.

    I looked but couldn’t find in which .php file I should make those change.
    I am using BuddyPress 1.6.1 as part of a template that I bought from Themeforest, template is called “reviewit”. ReviewIt is built as a BuddyPress/bbPress theme as far as i know.


    cwjordan
    Participant

    @cwjordan

    Instead of the template change suggested above, it works better to add the following

    /* set default BP to profile page instead of activity page */
    define( 'BP_DEFAULT_COMPONENT', 'profile' );
    

    in your wp-content/plugins/bp-custom.php file (create that file if it does not exist – see https://codex.buddypress.org/plugindev/bp-custom-php/ for more about that file).

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘Change first page shown for user profile’ is closed to new replies.
Skip to toolbar