Yes, I am having same issue as @julianprice reported and it’s in BuddyPress 2.2-beta version.
Have you tried to use BP repair tools ?
dashboard > tools > buddypress
I am reverted for testing to Twenty-fourteen Theme, using 4.1. I am using BuddyPress 2.1.1 and settings to allow activity stream commenting on blog and forum posts and our discussion settings in WordPress are that users do not need to login to comment, we also do not require an email to comment. Blog post comments appear in the activity stream; however, for comments by non-members there is no name. I presume this is expected behavior since the comment author does not have an email address and there user_id is 0. I found a few threads that pointed to a solution for similar behavior, but these regarded whether or not the blog was set to public. Ours is set to public, so I don’t think this is the case.
Is there a way to use get_comment_author from WP if the email address is blank? After much reading and reading on this, but having little experience with PHP, I traced this as expected behavior possibly to bp-blogs-functions.php, starting around line 556 I believe:
// Get the user by the comment author email.
$user = get_user_by( ’email’, $recorded_comment->comment_author_email );
// If user isn’t registered, don’t record activity
if ( empty( $user ) )
return false;
Is there a way I could achieve something like this instead?
// Get the user by the comment author email.
$author = get_comment_author( $comment_id );
$user = get_user_by( ’email’, $recorded_comment->comment_author_email );
// If user isn’t registered, don’t record activity
if ( empty( $user ) )
return $author;
Or anything else suggested?
Hi @disha76
Check out the BuddyPress Template Hierarchy article. The files you need to modify might not be created on your installation – they’re not created by default. You might need to create them yourself. The article will have lots more info on how this can be done.
@ubernaut @henrywright http://jetpack.me/2013/06/10/moving-sharing-icons has some instructions. Do you know in which of the buddypress files we need to put these to show “Likes” button in the river?
Hi there,
I’m quite new to buddypress. Currently using it to set up a community-driven marketplace. Direct messaging between potential customers and suppliers is an important feature – but it’s vital that we (the admin) may see these messages.
I’m quite sure that this was possible on my (under-construction) site a few weeks ago, just adding a “/messages” at the end of each users url
But now this doesn’t work anymore!
I tried to deactivate some plugins – without any result. Did maybe anything change with buddypress or wordpress during the last updates? or do you have any other ideas?
And does this “/messages”-trick work for you (being logged in as admin)..?
Thanks!!
Aaron
Hi,
reffering to this thread I am experiencing the following:
https://buddypress.org/support/topic/bugs-between-bbpress-and-buddypress/
If user create a public group and decide to change the group from public to private, the group becomes private, but the group forum doesnt. So the private posts from a private group appear in global activity stream. I tried the ‘recaculate relationships’ tool, but it has no impact.
Creating private group with private forum works fine. Its just the change from one mode to another, that has not impact on the forum settings.
Thanks for help.
Daniel
Possibly. That’s what you’ll need to check. Quite often the problem is theme- or plugin-related. My advice is to set up a test site which replicates your production site. Then you can make changes (for testing purposes such as this) without impacting your live website.
If the problem remains after you’ve disabled all plugins and activated the default theme then you can raise a ticket on Trac. The core development team can then take a look.
I did believe BuddyPress was made for WordPress usage…
@henrywright thanks for the reply!
I’m not sure I explained myself well. What I’m looking for is after the user has signed up and comes back another time and logs in. When they log in I don’t want them to go to the homepage, I want them to go to their activity page which the “Social Login” plugin will automatically do if I give it the right URL code.
For example, for post names the permalinks code is http://mywebsite.com/sample-post/ and then it fills in the part that says “sample-post” with the name of the page, for instance it would fill in “About” for the about page so the permalink would look like: http://mywebsite.com/about/. I need the code for how Buddypress fills in the part that would put in the username. I was thinking it might be /user-name/ or /%username%/ or something like that, but they didn’t work.
BuddyPress encourages its users to find and report bugs.
And they are even happier when a bug report includes a fix!
If you have found a bug, please open a ticket on trac.
I am sorry, I thought this is their support system. I will report it there then.
Here is one more:
PHP Notice: Undefined offset: 1 in /wp-content/plugins/buddypress/bp-activity/bp-activity-functions.php on line 1769
Does this belong here?
bp_core_new_nav_item doesn’t accept link or href parameters.
And the slug use /bp_loggedin_user_domain/$slug/ so you can’t add directly an arbitrary link with this parameter.
bp_core_new_nav_item and bp_core_new_subnav_item are respectively the buddy menu and the sub-menu, with each his own parameters. Same technique, but slightly different.
But you can hook into the function to modify the slug array, like this:
function bpfr_menubar_link() {
global $bp;
$bp->bp_nav[$slug] = array(
'name' => 'My super link',
'slug' => 'super_link',
'link' => 'https://buddypress.org',
'css_id' => 'super-link',
'position' => 20
);
}
add_action( 'bp_core_new_nav_item', 'bpfr_menubar_link', 999 );
Be aware that this nav menu is always user dependant, meaning that you will only see that link when you’re on your profile page. It won’t show when you’re on another members profile or not logged in. π
Hi
I want to redirect from one page to another with the help of if statement in functions.php
Here is what I want :
if user is logged in and is on link “/me” then redirect to
“<?php bp_loggedinuser_link() ?>”
What I am trying to do is make a single link for buddypress dynamic links. So, if someone goes to “/me” he would be redirected to if own profile page.
Can anybody tell me that how to write the above in form of code?
Thanks
@djsteveb,
pagination itself has nothing to do with the DB. bp-options contains only the number of items to show per page.
Do you use a custom pagination loop in bp-custom.php or child-theme’s functions.php ?
Or any other custom function related to groups ?
Did you checked your server error log ?
Have you some js or css errors ?
Try to modify the number of groups per page to show on the group directory. From 15 to 5 for example.
Or try to enter the url like this: mysite dot com/groups/?grpage=2&num=7
Hi @lustek
Regarding your new question, BuddyPress uses wp_hash() to hash the user’s ID with the result used as the activation key. So for example:
$activation_key = wp_hash( $user_id )
Unfortunately, we don’t have an exporter/importer for BuddyPress yet. I’ve asked around to see if anyone’s built one, but you might have to end up exporting/importing the MySQL database tables, which can be pretty tricky.
What is the “mindfulness-resources” page — do you have that set as the home page for your site, or is it mapped to one of the BuddyPress components (which one)?
It would also be useful to know what plugins and themes you have on your site. I wonder if something’s messing with the rewrite rules, we can try to help you figure it out.
I’m not sure, but it sounds like your line of thought is valid. Using a cookie for this seems a bit weird, but hey, that’s how it’s been implemented at the moment. π
If when you finish working through things, you still think you’re onto a bug with the missing cookie idea, please would you submit an explanation of the issue over on our bug tracker at https://buddypress.trac.wordpress.org/newticket ?
Continuing thread from wordpress.org:
Anytime I navigate to the activity feed on buddypress and then back to a main page in my navigation I receive a 404 page not found. I can reset the issue by re-saving permalink settings.
After troubleshooting I discovered that the in the wordpress parse_request function, a different rewrite rule is being matched when it breaks. When it is not working the regexp ([^/]+)(/[0-9]+)?/?$ is matched.
request uri:string(21) “mindfulness-resources”
new match: ([^/]+)(/[0-9]+)?/?$ Query: index.php?name=$matches[1]&page=$matches[2]array(2) {
[0]=>
string(21) “mindfulness-resources”
[1]=>
string(21) “mindfulness-resources”
}
When it is working the same block returns the output below and (.?.+?)(/[0-9]+)?/?$ is matched.:
request uri:string(21) “mindfulness-resources”
new match: (.?.+?)(/[0-9]+)?/?$ Query: index.php?pagename=$matches[1]&page=$matches[2]array(2) {
[0]=>
string(21) “mindfulness-resources”
[1]=>
string(21) “mindfulness-resources”
}
The only two differences I can detect is that the rewrite array order is different for these two rules and when its working the (.?.+?)(/[0-9]+)?/?$ rule is higher and thus encountered by the rule matching loop first. I have not been able to find the reason the order changes.
I fixed this by adding the following lines to wp-includes/class-wp.php which is not an ideal solution
if(isset($rewrite['([^/]+)(/[0-9]+)?/?$']))
{
$temp = $rewrite['([^/]+)(/[0-9]+)?/?$'];
unset($rewrite['([^/]+)(/[0-9]+)?/?$']);
$rewrite['([^/]+)(/[0-9]+)?/?$'] = $temp;
}
right after the line below in the function parse_request().
// Fetch the rewrite rules.
$rewrite = $wp_rewrite->wp_rewrite_rules();
Hi,
Trying to modify the BuddyPress plugin ‘BuddyPress JM Resume’ so that it will point to my own custom resume pages. The plugin uses this code to add a ‘resume’ tab to the profiles in BuddyPress:
function setup_nav( $nav = array(), $sub_nav = array() ) {
$nav_name = __( 'Resume', 'buddypress_jm_resume' );
// Add 'hrm' to the main navigation
$main_nav = array(
'name' => __( 'Resume', 'buddypress_jm_resume' ),
'slug' => $this->id,
'position' => $this->menu_order,
'screen_function' => 'bp_jm_resumes',
'default_subnav_slug' => 'resume',
);
// Determine user to use
if ( bp_displayed_user_domain() ) {
$user_domain = bp_displayed_user_domain();
} elseif ( bp_loggedin_user_domain() ) {
$user_domain = bp_loggedin_user_domain();
} else {
return;
}
parent::setup_nav( $main_nav, $sub_nav );
}
I would like to change this so instead of the tab going to the resume section it would take them to a page using something like:
“/resume/#user_name#/”
Is this possible?
Hi
Is there anyway to set ‘tags’ for users as a taxonomy, similar to how tags are used for WP posts?
To my knowledge, this isn’t built in to the current template hierarchy.
Ref:
Template Hierarchy
You could open a ticket on Trac requesting the enhancement (try searching open tickets first to make sure it isn’t already planned).
https://buddypress.trac.wordpress.org
Default BP does allow to see other usersβ Favorits in the Favorit tab in Profile page β why does Buddyboss kills this? At least site admin should be able to turn it on or off.
I see what you mean. We will consider adding an admin option.
Buddyboss is never meant to load every plugin but if a chosen few are bundled, it will be really good rather than re-inventing wheels at premium plugins, features of which are already available in the WP-BP repo. If users like us see thay they are well integrated into the Buddyboss look and feel there can be more sales of the Buddyboss theme actually.
I appreciate all of the feedback, very much. Our plan is to expand on these plugins and make them more feature rich, launch more premium plugins and themes, and also free plugins for the community over the year.
We launched two free plugins this week which you may be interested in:
Search all BP components in one unified dropdown:
https://wordpress.org/plugins/buddypress-global-search/
Edit BP activity from the front-end:
https://wordpress.org/plugins/buddypress-edit-activity/
@danbp
This works great. Thanks.
I could also change
'link' => bp_get_activity_directory_permalink(),
to
'link' => 'http://google.com',
and it worked as expected.
I also tried my hand at bp_core_new_nav_item ('<li>https://codex.buddypress.org/developer/function-examples/core/bp_core_new_nav_item/</li>')
But I am unable to add an arbitrary link to nav item. If I add a link declaration as in the case of sub nav. it gives out an error.
Parse error: syntax error, unexpected ''link'' (T_CONSTANT_ENCAPSED_STRING), expecting ')' in /.../wp-content/themes/nu-white-child/functions.php on line 35
Probably because the function does not expect a ‘link’ parameter.
How do I add an arbitrary link to the nav item?