Skip to:
Content
Pages
Categories
Search
Top
Bottom

Certain BuddyPress Member Profile Data Getting Hyperlinked [Resolved]

  • @frank13

    Member

    Very odd behavior in BuddyPress. When we enter various pieces of information in the About Me textbox on the members profile data in BP, some content is getting hyperlinked as `../members/?s=my content`

    Has anyone seen that? How can I correct it or shut off the hyper-linking?

    Thanks.

Viewing 10 replies - 1 through 10 (of 10 total)
  • @modemlooper

    Moderator

    Search here to remove links in profile fields. It’s a BuddyPress feature for searching users who are similar

    @frank13

    Member

    @modernlooper — I just searched this support forum for “remove links in profile fields” and got very strange and non-related results. So I still don’t know how to fix the glitch.

    @modemlooper

    Moderator

    It’s not a glitch it’s a feature.
    add (to a plugin, to your theme’s functions.php file, or to your bp-custom.php file)
    remove_filter( ‘bp_get_the_profile_field_value’, ‘xprofile_filter_link_profile_data’, 2 );

    @frank13

    Member

    Oh, ok @modemlooper. I thought it was a glitch because there is no pattern to what or why it selects certain text. On the surface it just seems totally random. I’ll give your remove_filter() a try.

    @frank13

    Member

    Ok I tried it @modemlooper. The certain random text is still hyperlinked.

    @modemlooper

    Moderator

    I might have written the filter wrong. google around its been discussed heavily on this forum

    @rogercoathup

    Participant

    Throw this in your bp-custom.php file to fix the glitch:

    remove_filter( ‘bp_get_the_profile_field_value’, ‘xprofile_filter_link_profile_data’, 9 );

    No idea who thought it was a good idea to automatically apply hyperlinks to all profile field content, or why. To make it worse, the priority number was changed in a recent release of BuddyPress, which is why the fix from @modemlooper no longer worked.

    @wesleysoccer

    Participant

    http://cl.ly/3f0o3y3z153J3a3r3L3h

    I added this

    <?php
    // hacks and mods will go here

    remove_filter( ‘bp_get_the_profile_field_value’, ‘xprofile_filter_link_profile_data’, 9 );

    ?>

    did not work in wp-content/plugins/bp-custom.php

    @wesleysoccer

    Participant

    Got it to work withe

    function remove_xprofile_links() {
    remove_filter( ‘bp_get_the_profile_field_value’, ‘xprofile_filter_link_profile_data’, 9, 2 );
    }
    add_action( ‘bp_init’, ‘remove_xprofile_links’ );

    added it to my bp-custom.php file.

    Thanks guys.

    @frank13

    Member

    I turned it off using the remover_filter(). Much better now :)

Viewing 10 replies - 1 through 10 (of 10 total)
  • The topic ‘Certain BuddyPress Member Profile Data Getting Hyperlinked [Resolved]’ is closed to new replies.
Skip to toolbar