Skip to:
Content
Pages
Categories
Search
Top
Bottom

[Resolved] Disabling @mentions

  • @ultimateuser

    Participant

    Hi,

    I’m using WP 3.6 and BP 1.8

    I’ve added add_filter('bp_activity_do_mentions', '__return_false');

    to my bp-custom.php file.

    However when I visit a Members Profile Page the @mention still displays below the name field.

    Any suggestions?

    Thank you

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

    Participant

    I’ve read this on: https://buddypress.org/2013/06/buddypress-1-8-beta1-is-now-available/

    But it doesn’t work for me, can anyone help?

    @dcavins

    Keymaster

    You can use r-a-y’s code to remove that pane:

    //Removes mentions pane from profile activity (doesn't remove mention functionality)
    function ray_remove_mention_nav() {
    global $bp;
    bp_core_remove_subnav_item( $bp->activity->slug, 'mentions' );
    }
    add_action( 'bp_setup_nav', 'ray_remove_mention_nav', 15 );

    It works on my 1.8+ test setup.

    -David

    @ultimateuser

    Participant

    Thanks will try that!

    @ultimateuser

    Participant

    I still don’t understand why adding:

    add_filter( ‘bp_activity_do_mentions’, ‘__return_false’ );

    to bp-custom.php or functions.php doesn’t work.

    This should complete disable mentions.

    Anyone knows why this doesn’t work?

    @hnla

    Participant

    It does work! I’ve just tested it for you and run from functions.php.

    @ultimateuser

    Participant

    @hnla I have put the code in my functions.php of my Child Theme. Mentions are still enabled. Is there anything else I can try?

    @ultimateuser

    Participant

    It seems to work partly:

    For example on a Members page it removed the Mentions tab. But I can still click ‘Public Message’ and use the mention function.

    @ultimateuser

    Participant

    I’ve got it working on the default BP theme my adding the code to functions.php

    It is however still not working on my child-theme.

    @tothlukas4

    Participant

    It’s working on my child-theme but I found that in your code aren’t apostropes…
    try this one instead
    add_filter( ‘bp_activity_do_mentions’, ‘__return_false’ );

    @sundev

    Participant

    @ultimateuser

    create bp-custom.php and place it in wp-content/plugins, not wp-content/plugins/buddypress.

    copy directly and paste the code below into bp-custom.php you created.

    add_filter( 'bp_activity_do_mentions', '__return_false' );

Viewing 10 replies - 1 through 10 (of 10 total)
  • The topic ‘[Resolved] Disabling @mentions’ is closed to new replies.
Skip to toolbar