UPDATE:
I’ve changed BuddyPress from being ‘network activated’ to just ‘activated’ on the main/root site. I don’t know what the recommended setup is these days, but we’ve had it network activated since BuddyPress only ran on WPMU.
Having it activated on the main site only means that the ‘bug’ now only affects the main site and not every site across the network. So the example I give above no longer shows the issue.
However, you can still see it on this page:
http://blogs.lincoln.ac.uk/test/
See how, whenever there is @lincoln.ac.uk either in the content of the page, or in a mailto link, BuddyPress injects a hyperlink with a random user’s email address following the root domain:
http://blogs.lincoln.ac.uk/amakrzanowska%40lincoln.ac.uk/
I’ve no idea how or why it’s constructing that URL and automatically inserting it whenever @lincoln.ac.uk is found in the body content.
Ideas much appreciated!
I’ve never seen that before. Standard advice is to switch themes and deactivate all plugins, then switch everything back one by one to see if a specific theme/plugin is the cause.
If not, BuddyPress does automatically inject links into some content. Profile fields for example, when viewing a user’s profile. Weird that it’s doing this on a random WP page though.
As for ‘network activated’ I suggest leaving it to just ‘activated’ on your main site that you’re running BP on. No reason to run it everywhere.
Hi again,
I still have this problem. I’m sure it’s BuddyPress that is the cause, as it still occurs with different themes and with all other plugins deactivated. When I deactivate BuddyPress, the problem stops.
Run your mouse over the links on this page, and you’ll see the issue: http://blogs.lincoln.ac.uk/test/
I was wondering whether it is a legacy of running BuddyPress since alpha/beta and whether there is an old setting in the database or something that I might look out for. Where are the BuddyPress settings stored in the database? None of the wp_bp tables look like they hold global settings.
In my wp-config.php file, I have the following:
define( ‘BP_ENABLE_ROOT_PROFILES’, true ); //removes the /members/ slug
define( ‘BP_DEFAULT_COMPONENT’, ‘custom-profile’ ); //defaults to profile page rather than activity stream of a user
define( ‘BP_ENABLE_USERNAME_COMPATIBILITY_MODE’, true ); //for LDAP compatibility
define ( ‘BP_IGNORE_DEPRECATED’, true );
define(‘BP_USE_WP_ADMIN_BAR’,true);
Thanks for any advice,
Joss
I suppose another way of looking at this would be to find the code in BuddyPress that injects hyperlinks into certain text, such as profile tags. Where would I find this?
Thanks.
For the record, I’ve narrowed it down to the ‘Activity Streams’ component of BuddyPress. When this is disabled, the problem does not occur.
… and if I activate ‘Activity Streams’ but add
add_filter( 'bp_activity_do_mentions', '__return_false' );
to bp-custom.php, the problem is resolved.
So it looks like, for some reason, I can’t have mentions enabled without the problem occurring. Can anyone think why?
Thanks,
Joss
Hi @josswinn
Is this ticket related to your problem by any chance?
https://buddypress.trac.wordpress.org/ticket/4680
Yes! That’s it. Thanks for pointing this out, Henry. I shall link the bug report to this thread and offer to help bug test.
Cheers
Joss