Skip to:
Content
Pages
Categories
Search
Top
Bottom

After WordPress 6.7 release, buddypress fails


  • wpuser
    Participant

    @forinn

    Hi there,

    My buddypress is updated to the latest verison. Today there was a major WordPress release (6.7) but after upgrading, my buddypress member list, friendships and friendlist stops working. Seems Buddypress needs an update as well, to work with the newest WordPress.
    Can you please update the plugin to fit with the latest Wordspress 6.7 as soon as possible?
    Thank you !!

Viewing 25 replies - 1 through 25 (of 32 total)

  • GyziieDK
    Participant

    @dreampixel

    Hello @forinn

    Works fine for me, so sounds like a third-party conflict or maybe an issue within your theme.

    Have you tried troubleshooting the issues? (Cleared cache, tested compatibility within plugins and so on?)


    wpuser
    Participant

    @forinn

    I already troobleshooted that ofcourse.

    I tried it with the basic twenty seven theme and with no other plugins enabled. I did not make any customizations.


    GyziieDK
    Participant

    @dreampixel

    Does sound like there is a conflict somewhere – no snippet codes enabled while troubleshooting?
    Could you provvide screenshots of what it looks like on your end? πŸ™‚


    wpuser
    Participant

    @forinn

    I installed a blank wordpress on a test environment, clean sheet.
    I installed a clean, blank install of buddypress.
    I use the lastest update of twenty seven theme.

    I have only 1 user, which is me (admin) of the test site, and I show up.
    I added a second user, via the admin, that did not show up.
    I added this user as a friend, this user show up in “my friends” but not in userlist.
    Than I did database repair (fix total members) and fix friendship total.
    Than the second user show up.

    But when trying to sort on “Alphabetical”, I get “no members found”

    All my plugins have been de-activated except for Buddypress.

    I tell you, something is wrong. Please believe me.

    This is the screenshot: https://ibb.co/W6drH8p

    I am not using caching of any kind. It is a clean install. No plugins or other things running. Only my theme and buddypress.

    Please do me a favor, go to your latest buddypress and wordpress version and try to use the userlist/friendlist, I am 1000% sure you are having the same issues.


    GyziieDK
    Participant

    @dreampixel

    Hello again πŸ™‚

    The user you’re setting up, is this a legit setup with a mail (where you can activate the account)?. If not, then maybe give this a try. Normally users must activate their accounts from a mail they receive upon registration before they’re visible on the directory.

    Also, what settings have you setup under the following:
    Settings > BuddyPress > Options

    This might make it easier for me to see if anything in there is the culprit. πŸ™‚


    GyziieDK
    Participant

    @dreampixel

    Please do me a favor, go to your latest buddypress and wordpress version and try to use the userlist/friendlist, I am 1000% sure you are having the same issues.

    Sorry, but works fine for me – even with latest update to BuddyPress Version 14.2.1.

    I even run a pretty complex site with a lot of software that needs to be compatible – including custom code setups and so on. Still works πŸ™‚


    GyziieDK
    Participant

    @dreampixel

    Try download this plugin – and switch to the user you created (can also be done from backend) – and “login” with that user. Normally users show up, when they have logged in after registration.

    Maybe that works. πŸ™‚

    User Switching


    wpuser
    Participant

    @forinn

    This is my settings: https://ibb.co/6twjgxB

    Nothing special.

    The second user was added via the admin by me. Should work, right? Because we do have that option, why would it not work? I could see the second user on the admin panel but not on the frontend.

    But even after I have logged in on my and my second account, still user list alphabetical does not work. Can you explain what the issue could be with the memberlist? Why does alphabetical not work? It worked before the update.


    GyziieDK
    Participant

    @dreampixel

    You can add users from back-end, yes.. but the users still need to “activate” their account and login for them to show up on the front-end (in directory).

    Does the member show up in the normal member directory? – and is the issue only with the “alphabetical search”? .. My alphabetical search works fine, so might be a theme compatibility issue.

    Have you cleared both server and browser cache?


    wpuser
    Participant

    @forinn

    Yes – cache is cleared.
    I tried on 2 different servers.
    I have used the basic wordpress theme – which was updated today.

    At this moment the issue is only with alphabetical. All 2 users are “activated”.

    I will send you a dm with link of the website url.


    GyziieDK
    Participant

    @dreampixel

    Sounds like compatibility issue within the theme then. Have you tried it with a BuddyPress supported theme?


    wpuser
    Participant

    @forinn

    I managed to locate the issue. After the wordpress update, it was not allowing my translations for the xprofile fields anymore. For some reason it has to be English now, it is no longer allowing it to be Dutch. I’ll flag this with the WordPress development team.

    I’ll close the topic as the issue is likely not because of Buddypress but because of WordPress.

    How can I resolve./close this topic?


    GyziieDK
    Participant

    @dreampixel

    Sounds weird, since I’m also using the user fields (xProfile fields) – my site is translated into Danish, but my site-admin back-end it set to English. This is due to it being easier to find items in the menu when troubleshooting (hate when settings and so on is translated lol).

    So seems weird to me if the translation part of it is causing the issue, since I’m also using it, but not having the same issue?

    Hope you find a solution and it ends up working for you though! πŸ™‚


    wpuser
    Participant

    @forinn

    On second thought… this is within the Buddypress coding, so something that must have changed for WordPress 6.7 is not interacting correclty anymore with Buddypress.

    The “Alphabetical” sorting of the user list is sorting on the “Name” base field of bp_xprofile_data table (field 1). This field I had renamed to “Naam” (which is Dutch for Name). This is hardcoded in the database and not avaibable as translation string. After switching back to “Name”, everything worked again. Before, I was allowed to use switch the name of the field. How do you translate this? I now have used a filter function in my functions.php, but it shouldn’t be necessary.

    Furthermore I discovered the memberlist is sorting on that particular “Name” field, instead of the “display name” I want to use. Any idea’s how to get the userlist to sort on display name instead of “Name” ? Why do we have a mandatory “Name” field anyway?


    wpuser
    Participant

    @forinn

    Also, I am no longer able to customize the order of my members list. I was using default alphabetical, but also that function no longer works.


    GyziieDK
    Participant

    @dreampixel

    Hello again πŸ™‚

    This might start to make sense then!

    First, when you translate something within the code itself (not using a translation plugin and po/mo file) it will for the most part be overridden whenever you update your WordPress / plugins that are translated. So, this might be why it doesn’t work now after the update.

    I personally use a combination of LocoTranslate and TranslatePress. This is because BuddyPress activity is updated the way it is and for that reason LocoTranslate itself is not able to translate the dynamic content (like when activity updates – without the page doing so) – this TranslatePress supports.

    So, for the BuddyPress content that can’t be translated correctly using LocoTranslate, I use the TranslatePress for those. Both plugins are free to use, and it doesn’t require you to purchase any expensive addons.

    It’s important that you pick the right placement for your translation-files (custom, author, system). If they’re not in the right place the translation might not show up on the front-end. Also make sure you setup the settings within the LocoTranslate plugin not to override your translated files upon updating WordPress: Loco Translate > Settings > File system access > Modification of installed files & Editing of POT (template) files must be set to Disallow.

    For the display name, this should be the default value it sorts by. Mine by default sorts by display name. When you go to Users > Profile Fields – you can edit the different settings from within there with the names and what is mandatory/not mandatory.

    For the sorting part (or other features in the future) if it still causes issues, maybe a snippet code using a plugin like WPCode Lite might be a better solution rather than going into the code and edit it from there. In this way it will not get affected in most cases when you update WordPress, plugins and theme.

    Maybe some of this can help you – if not – then feel free to keep me updated. πŸ™‚


    GyziieDK
    Participant

    @dreampixel

    Also please note that the name field marked in the Users > Profile Fields with “(Primary)” IS the display name itself. This should be the field users use upon registration of their user – and this is also the field the BuddyPress Member Directory uses to sort content Alphabetical.


    thinlizzie
    Participant

    @thinlizzie

    I just wanted to thank @dreampixel for the support they are giving here on the site. It’s very refreshing. Usually no help whatsoever is offered by any of the people behind Buddypress. None.


    wpuser
    Participant

    @forinn

    Also from my side, very much appreciated all the help and effort -> sorry for not mentioning that before! I was so hyperfocussed on the issue that I forgot human interaction.

    Anyways, again, thank you.

    To further empathize what I mean with the display name is this:

    Screenshot of a test user I just registered via the normal process on the website signup form:
    v1

    You see username, nicename, display name are automatically set same as the username (which is debbugger)
    I filled the “Name” field on signup with “Annie”, as a random name. and some other random fake user information. As you can see “Annie” is not showing up, only that “debugger” which I choose as my username.

    Screenshot of bp_xprofile_fields, where you can see the “Name” base field (1):
    v2
    As you can see, “Name” is hardcoded in the database. And this is mandatory. I had this translated to “Naam” before, but after the wordpress update, that was no longer allowed. It took me days to figure that out, but I am happy I found out. This thing was the sole reason everything like friendlist, userlist, etc. did not work anymore. Please note I am not allowed to rename or change any setting with regards to this field. I am also not allowed to delete it. I am stuck with it, it seems.

    (1/2)


    wpuser
    Participant

    @forinn

    Screenshot of test user “debugger” field information in bp_xprofile_data:
    v3
    On the screenshot you can see field name 1 (Name) come in as “Annie”. So, this is not the same field and not the display name. The display name CAN become “Annie”, when i choose to change it after I edit my profile, but not as standard, than it will use my username. This is also the desired situation, I want people to show with their usernames.

    So, after the WordPress update the following has changed:
    – It is now mandatory to use “Name” for mandatory base field, I am not allowed to translate that. I can do it probably with Translate press as you suggested and I will look into that. But it is a new thing, it was not like that before. Thanks for your suggestion!
    – The “Alphabetical” sorting option in the memberlist is now sorting on this “Name” field and not on the “display name”. If a user their username is for example: robinhood and their “name” is “patrick”, it will give a really weird non-alphabetical result in the userlist, as you can still see their usernames, but the sorting is now done on a different field than before. Do you follow?

    Anyway, I would like to have it that it sorts by default on alphabetical and that it will sort on “display name” rather than “Name”.

    Do you think this is a release bug, or is this change intentional?

    Any suggestions? Wait for a fix, or will it have to be manual code in wpcode?

    Thanks for your support again.

    (2/2)


    GyziieDK
    Participant

    @dreampixel

    I just wanted to thank @dreampixel for the support they are giving here on the site. It’s very refreshing. Usually no help whatsoever is offered by any of the people behind Buddypress. None.

    Hello @thinlizzie πŸ™‚

    I’m by no means an expert or anything lol, but I’ve been playing around with WordPress and numerous different large setups for the past 15+ years. I normally reply to people if I got the time or ideas on what could be done.

    That is not my experience that there is no support in here. Please remember that BuddyPress is open source and the users in here (mods included) are not obligated to help/offer support all the time. Most people in here have other projects going on and/or might not be able to help. Also, a lot of the time the same issues are highlighted again and again instead of people searching the forums for answers first.

    That being said, I also appreciate when people try to help me troubleshooting, since it can be quite frustrating when things doesn’t work, and you have people depending on it.


    GyziieDK
    Participant

    @dreampixel

    @forinn I’m trying to upload a reply, but it’s not letting me lol. I’m getting back to you with an answer asap when it lets me post.


    GyziieDK
    Participant

    @dreampixel

    Hello again @forinn

    I hate to make a different txt-document since it would not let me upload a longer answer in here and then started to refuse because of duplicate posting. Anyways, see my attached answer from the link below.

    https://jumpshare.com/s/G4ocRkpfKm3w25l4qrjD

    Hope it helps! πŸ™‚


    GyziieDK
    Participant

    @dreampixel

    If you want the “Name” (display name) to always be set by default to “username”, you can add this code into your functions.php (or preferable using the Snippet Code plugin WPCode – with a PHP snippet code).

    This should setup the default display name to always show the “username” when creating new user profiles.

    // Function to set the display name to the username for new users or profile updates
    function bp_sync_display_name_with_username($user_id) {
        // Get the user data
        $user_info = get_userdata($user_id);
        
        if ($user_info) {
            // Get the username
            $username = $user_info->user_login;
    
            // Update display_name to the username
            wp_update_user(array(
                'ID' => $user_id,
                'display_name' => $username
            ));
        }
    }
    
    // Hook the function to user registration and profile update actions
    add_action('user_register', 'bp_sync_display_name_with_username');
    add_action('profile_update', 'bp_sync_display_name_with_username');

    Also, you can add another function to sort by alphabetical by default if this continues to be causing you issues.

    // Function to set default BuddyPress member sorting to alphabetical
    function bp_default_members_sorting_alphabetical($args) {
        // Check if the 'type' is not set, set it to 'alphabetical'
        if (empty($args['type'])) {
            $args['type'] = 'alphabetical';
        }
        return $args;
    }
    
    // Apply the filter to the member query arguments
    add_filter('bp_after_has_members_parse_args', 'bp_default_members_sorting_alphabetical');

    Let me know if that works for you.


    wpuser
    Participant

    @forinn

    Hi there,

    I had the issue with posting a reply yesterday too. Weird.
    That is why I split my message in 2 and than I could post it.

    I was able to read your share txt and the next replies and also view that images.

    Anyway… I am willing (if you are willing to put the time in it) to give you access to my staging site, but I rather not post the link in public, to avoid traffic from Google and such to that staging website. But there does not seem to be a way to share the link with you in private. Do you have any suggestions?

    To further explain my situation: I did not make any customizations to my buddypress or xprofile plugin that have anything to do with the profile fields. From the clean install, the “Name” field is already there from the start, when installing the buddypress plugin.

    I am not adding users via the admin section, I am letting them signup via the website register form. So following this process, the situation is as described before, where the “Name” will be filled in by the user as part of the registration process. The Name field is mandatory, set by Buddypress, which I can not influence nor rename.

    I did nothing to influence the Name field, other than translating it like I explained before.
    The Name is operating as a seperate field, that does not seem to link to username by default. And that is also not what I want. Because it would lead to the username being shown twice on a profile page, which is ridicilous of course. Since you can not block or hide the Name field, it will be there. Also, the Name field is always on the register form, and the field is mandatory (which you cannot change), so people CAN and probably will fill in something different than their username. Most likely their first name. Which is what happened on my site anyway, people fill in their regular first name. Only a handfull will choose like a second username/nickname for the field value. Anyway, in 99% process of the time, the Name field is populated with a different value than the username as a result of the website registration process (which is not changed, it is by default like that, since installing buddypress).

    I use the BuddyX theme. But the issue is not related to the theme, because using a default WordPress theme (like twenty two or so), will have the same result.

    So, it poses as a problem, if the usernames show up on the userlist, but the sorting will go on the “Name” field, which is not identical to the username. This will lead to a really undesired situation, where the sorting does not seem to work properly on the frontend, because “invisible” the userlist is sorted on the Name field.

    And also, this is new. Before, this was not the case. It did NOT sort on the “Name” field. And I’m oblivious why it does now, what is the intent by changing this.

    So, to address the situation, and to avoid having duplicate usernames on the profile page, I would rather stick with people using the Name field as their first name or something like that.

    I would like to sort on display name. Is there a way to do that? Do you have a suggestion?

Viewing 25 replies - 1 through 25 (of 32 total)
  • You must be logged in to reply to this topic.
Skip to toolbar