I think this is one of those small things that should be added to BuddyPress core, but the following snippet allows you to change the default Notification settings for new users. This snippet is taken directly from the BuddyDev blog. Buddydev is run by my friend Brajesh and his team who’ve been providing the community with free and premium plugins for years.
Add the code below to bp-custom.php
Note: This functionality is also available as a premium plugin on BuddyDev. Check it out!
I found this quick little snippet on the BuddyBoss support forums, and thought i’d share it here. The snippet below will display an user @mention name directly below their avatar within a BBPress forum topic.
It’s often in the small things, and this post will give you two small but valuable tricks that make the lives of your community members a lot easier.
Trick #1: Automatically check the “Remember me” box on your login form.
Add the following snippet to bp-custom.php
This quick snippet will automatically check the “remember me” checkbox on your front-end and wp-login.php login form. Sweet!
Trick #2: Extend the default login cookie expiration length
By default a user is logged out after 48 hours or when closing their browser completely. That is certainly less than ideal for a social network. The snippet below changes this only logout after a month of inactivity. Much better huh?
After you’ve downloaded and installed the plugin your default WordPress search form will be modified automatically to display your new BuddyPress Global Search results. So that means there’s nothing you have to behind the scenes. Install & Activate!
After installing and activating the plugin everything worked exactly as advertised. Searching is fast, accurate and my custom post types (Videos) where shows in the search results as well. Superb!
When I write my CSS/LESS I often use body classes to target elements on specific pages on my site. BuddyPress does a good job of adding it’s own custom body classes to the BuddyPress pages, but it also inherits some of the WordPress classes like .page. The snippet below adds a simple body class wordpress-page to all regular WordPress pages. This allows you to write custom CSS that is only applied to WordPress pages without affecting the styling of BuddyPress content.
Add the following to bp-custom.php
Here’s a quick example of how you could then use this.