Skip to content

Instantly share code, notes, and snippets.

@imath
Created September 18, 2014 22:26
Show Gist options
  • Star 4 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save imath/5a3c4ac645ec765863f2 to your computer and use it in GitHub Desktop.
Save imath/5a3c4ac645ec765863f2 to your computer and use it in GitHub Desktop.
add BuddyPress auto suggest mention feature in bbPress.
<?php
/** You could put this in the bp-custom.php file
* @see http://codex.buddypress.org/themes/bp-custom-php/
*/
function custom_bbpress_maybe_load_mentions_scripts( $retval = false ) {
if ( function_exists( 'bbpress' ) && is_bbpress() ) {
$retval = true;
}
return $retval;
}
add_filter( 'bp_activity_maybe_load_mentions_scripts', 'custom_bbpress_maybe_load_mentions_scripts' );
@kellbot
Copy link

kellbot commented Dec 18, 2014

Super handy, thanks for this!

@jackofallvices
Copy link

This hack works except that it does NOT work on group created forums. Any ideas on how to fix this?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment