BuddyDev

Search

Want to put XProfile – About Me text inside Cover photo

  • Participant
    Level: Master
    Posts: 392
    Daniel on #20247

    Hi

    I have here a code of the old Theme in order to show users Xprofile “About Me” inside the Cover Photo but unfortunately it doesn’t work for the Nouveau Theme when I add it to child functions.php or bp-custom.php file.

    Would it be possible to adjust the code in order that it works for the nouveau theme?

    add_action( 'bp_before_member_header_meta', 'thrive_bp_before_member_header_meta_about' );
    function thrive_bp_before_member_header_meta_about() { ?>
    <?php
    $field_name = 'Over mij';
    $about_user = @bp_get_member_profile_data( 'field=' . $field_name );
    ?>
    
    <?php if ( ! empty( $about_user ) ) { ?>
    
    <p class="thrive-about-user">
    
    <?php echo esc_html( $about_user ); ?>
    
    </p>
    
    <?php } ?>
    <?php }

    Thank you.

    Regards
    Daniel

You must be logged in to reply to this topic.

This topic is: not resolved