Skip to:
Content
Pages
Categories
Search
Top
Bottom

[Resolved] Change default view in profile (BP 1.2)


  • hugodouchet
    Participant

    @hugodouchet

    Hi all,

    My BP works great now (thanks for BP forum members help).

    Now, i would like to show by default the profile view when viewing member profile (by default it’s the “Activity” tab).

    I use BP 1.2

    Thank’s a lot

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

  • peterverkooijen
    Participant

    @peterverkooijen

    Change the template tags in the template files, I think profile/index.php


    hugodouchet
    Participant

    @hugodouchet

    Hi

    I don’t know how to do.

    The default profile index :

    <div id="item-body">

    <?php if ( bp_is_user_blogs() ) : ?>

    <?php locate_template( array( 'members/single/blogs.php' ), true ) ?>

    <?php elseif ( bp_is_user_profile() ) : ?>

    <?php locate_template( array( 'members/single/profile.php' ), true ) ?>

    <?php elseif ( bp_is_user_activity() || !bp_current_component() ) : ?>

    <?php locate_template( array( 'members/single/activity.php' ), true ) ?>

    <?php elseif ( bp_is_user_friends() ) : ?>

    <?php locate_template( array( 'members/single/friends.php' ), true ) ?>

    <?php elseif ( bp_is_user_groups() ) : ?>

    <?php locate_template( array( 'members/single/groups.php' ), true ) ?>

    <?php elseif ( bp_is_user_messages() ) : ?>

    <?php locate_template( array( 'members/single/messages.php' ), true ) ?>

    <?php endif; ?>

    <?php do_action( 'bp_directory_members_content' ) ?>

    </div><!-- #item-body -->

    And my try (but seems dont work) :

    <div id="item-body">

    <?php if ( bp_is_user_blogs() ) : ?>

    <?php locate_template( array( 'members/single/blogs.php' ), true ) ?>

    <?php elseif ( bp_is_user_profile() || !bp_current_component() ) : ?>

    <?php locate_template( array( 'members/single/profile.php' ), true ) ?>

    <?php elseif ( bp_is_user_activity() ) : ?>

    <?php locate_template( array( 'members/single/activity.php' ), true ) ?>

    <?php elseif ( bp_is_user_friends() ) : ?>

    <?php locate_template( array( 'members/single/friends.php' ), true ) ?>

    <?php elseif ( bp_is_user_groups() ) : ?>

    <?php locate_template( array( 'members/single/groups.php' ), true ) ?>

    <?php elseif ( bp_is_user_messages() ) : ?>

    <?php locate_template( array( 'members/single/messages.php' ), true ) ?>

    <?php endif; ?>

    <?php do_action( 'bp_directory_members_content' ) ?>

    </div><!-- #item-body -->


    modemlooper
    Moderator

    @modemlooper

    || !bp_current_component()

    I think you should move that to blogs.


    hugodouchet
    Participant

    @hugodouchet

    Hi Modemlooper,

    I think too, but dont works!! :(

    I move it to “profile” but no change.

    Simple. In wp-config.php:

    define( 'BP_DEFAULT_COMPONENT', 'profile' );


    hugodouchet
    Participant

    @hugodouchet

    Hi Andy,

    You’re the best!! :D

    Yeah, it’s so simple when we have answers… :p

    Thanks for your job, all Automatic projects rocks!

    Good luck for the next!


    noriise
    Participant

    @noriise

    It’s all about 3 year old posts. Just to say, better to add this to functions.php


    jadportado
    Participant

    @jadportado

    Hey, still works like magic! Thanks 🙂

Viewing 8 replies - 1 through 8 (of 8 total)
  • The topic ‘[Resolved] Change default view in profile (BP 1.2)’ is closed to new replies.
Skip to toolbar