Skip to:
Content
Pages
Categories
Search
Top
Bottom

Removing Profile Field Links

  • @danielfelice

    Participant

    Hi Everyone,

    I think this question was asked a while back but I cannot find it in the forums.

    I am wondering how to remove the auto linking in the profile info fields on the member page. I want to remove the link for the members name and replace it with the link the user enters for the URL.

    So the members name in the profile info area links to they specify when signing up.

    Thanks

    Dan

Viewing 5 replies - 1 through 5 (of 5 total)
  • @danielfelice

    Participant

    anyone?

    @djpaul

    Keymaster

    I need to do something like this today so when I get somewhere I will update here.

    @djpaul

    Keymaster

    Aloha. You can use this for starters:

    function df_xprofile_filter_link_profile_data( $field_value, $field_type = 'textbox' ) {
    global $bp, $field;

    remove_filter( 'bp_get_the_profile_field_value', 'xprofile_filter_link_profile_data', 2, 2 );

    if ( 1 == $field->group_id && 'Name' == $field->name )
    return 'change this to whatever you want';
    else
    return xprofile_filter_link_profile_data( $field_value, $field_type );
    }
    add_filter( 'bp_get_the_profile_field_value', 'df_xprofile_filter_link_profile_data', 1, 2 );

    This is edited from what I’m using for so not guaranteed to work first time.

    @danielfelice

    Participant

    Thanks! I’ll give it a go and let you know how it works!

    @danielfelice

    Participant

    works great, it replaces the name “with whatever i want here”

    now…. :)

    how do i get it to display the members name, and also create a link to the URL the user enters in for “website”, which is currently question 3 in the profile info

    i played around with it, but just kept breaking things!

    thanks

Viewing 5 replies - 1 through 5 (of 5 total)
  • The topic ‘Removing Profile Field Links’ is closed to new replies.
Skip to toolbar