Skip to:
Content
Pages
Categories
Search
Top
Bottom

Search Results for 'buddypress'

Viewing 25 results - 726 through 750 (of 69,210 total)
  • Author
    Search Results
  • #332972
    Varun Dubey
    Participant

    @eluyawi

    You can use the following code snippet to create a new tab to display at BuddyPress Profile.

    // Function to add a custom tab for Membership Details in the BuddyPress profile
    function wbcom_rcp_buddypress_add_membership_tab() {
        global $bp;
    
        // Define a new navigation item for the BuddyPress profile menu
        bp_core_new_nav_item(array(
            'name' => __('Membership', 'textdomain'), // The name of the tab
            'slug' => 'membership', // The slug for the tab, used in the URL
            'screen_function' => 'wbcom_rcp_buddypress_membership_screen', // The function that will load when the tab is clicked
            'position' => 50, // Position of the tab in the profile navigation
            'parent_url' => bp_loggedin_user_domain() . '/membership/', // The parent URL for this sub-navigation
            'parent_slug' => $bp->profile->slug, // The slug of the parent navigation item
            'default_subnav_slug' => 'membership' // Default sub-navigation slug
        ));
    }
    
    // Function to handle the display of the Membership Details tab content
    function wbcom_rcp_buddypress_membership_screen() {
        // Add the title and content to the Membership tab using actions
        add_action('bp_template_title', 'wbcom_rcp_buddypress_membership_screen_title');
        add_action('bp_template_content', 'wbcom_rcp_buddypress_membership_screen_content');
        // Load the BuddyPress plugin template for displaying the tab content
        bp_core_load_template(apply_filters('bp_core_template_plugin', 'members/single/plugins'));
    }
    
    // Function to set the title of the Membership Details tab
    function wbcom_rcp_buddypress_membership_screen_title() {
        echo 'Membership Details'; // Title displayed on the Membership tab
    }
    
    // Function to display the content of the Membership Details tab
    function wbcom_rcp_buddypress_membership_screen_content() {
        // Use the shortcode [subscription_details] to display membership information
        echo do_shortcode('[subscription_details]');
    }
    
    // Hook the function to add the Membership tab into the BuddyPress setup navigation action
    add_action('bp_setup_nav', 'wbcom_rcp_buddypress_add_membership_tab');
    

    You can use a plugin to add code snippets to your WordPress website using a plugin like “Code Snippets.” This plugin allows you to add custom PHP code snippets to your site without editing your theme’s functions.php file.

    #332971

    In reply to: Profile picture issue

    Varun Dubey
    Participant

    @fourbfb you can try to debug with the following steps.

    1- Temporarily deactivate other plugins to rule out conflicts, as another plugin might interfere with BuddyPress’s upload functionality.
    2- Switch to a default WordPress theme like Twenty Twenty to check if the issue is theme-related.
    3- Verify PHP settings such as upload_max_filesize and post_max_size are adequate in your php.ini file.
    4- Use the browser’s developer console (F12) to check for JavaScript errors that might block the upload process.
    5- Ensure that the profile photo and group icon uploads are enabled in BuddyPress settings.

    erisf
    Participant

    Hello, I’d like to modify the buddypress registration page (site.url/register). I can’t find a page with that name in my page list, it isn’t there when editing the theme, and editing the fields under users isn’t enough for me.

    I want to modify the APPEARANCE of the page, along with the APPEARANCE of all other buddypress pages, like the modify/reset password pages, and everything else that’s needed for user registration.

    Any help?

    eluyawi
    Participant

    Hi There,

    How can I add the section membership account of Restrict-content-PRO plugin (It’s a shorcode [subscription_details]) as a new field in the Buddypress dashboard?

    #332955
    eluyawi
    Participant

    Hi there,
    I have installed BuddyPress and have been testing it, and I have an error.

    When I edit my Name and save the changes. At the moment the changes do not appear, but I have checked in the Users section of WordPress that they have been saved.

    How can I make the changes appear once you hit the save button? can you help me?

    Thans

    #332953
    riazoo518
    Participant

    Hi,
    Have you tried checking your SMTP settings in BuddyPress directly? Ensure they align with the configuration in WP Mail SMTP plugin. Additionally, verify if your hosting provider has any specific requirements for SMTP setup. You may need to coordinate with them to improve email deliverability. Good luck!

    #332951
    Varun Dubey
    Participant

    Either Ultimate Member or BuddyPress; you can not use both together.

    #332948
    martenw
    Participant

    Warning in BP 12.2.0

    [25-Jan-2024 02:32:13 UTC] PHP Warning: Attempt to read property “activity” on null in /var/www/eufort-sokolniki/wordpress/current/wp-content/plugins/buddypress/bp-activity/bp-activity-template.php on line 643
    [25-Jan-2024 02:32:13 UTC] PHP Warning: Attempt to read property “id” on null in /var/www/eufort-sokolniki/wordpress/current/wp-content/plugins/buddypress/bp-activity/bp-activity-template.php on line 643

    #332947
    Varun Dubey
    Participant

    🙂 Depending on your website’s plugins, theme, and any custom BuddyPress codes. BuddyX is ready for BPv12+ it does not need BP Classic. All our plugins are also ready for BPv12+.

    Varun Dubey
    Participant

    @thesun2012 bp_legacy_theme_ajax_messages_star_handler is not mandatory; you can also create your custom handler based on it
    for example

    function wbcom_custom_buddypress_ajax_handler() {
        check_ajax_referer('custom-bp-ajax-nonce', 'security');
    
        $displayed_user_id = isset($_POST['displayed_user_id']) && !empty($_POST['displayed_user_id']) 
                             ? (int) sanitize_text_field($_POST['displayed_user_id']) 
                             : get_current_user_id();
    
        $message_id = isset($_POST['message_id']) ? (int) sanitize_text_field($_POST['message_id']) : 0;
        $star_status = isset($_POST['star_status']) ? sanitize_text_field($_POST['star_status']) : '';
        $bulk = isset($_POST['bulk']) && !empty($_POST['bulk']);
    
        if (!bp_is_active('messages', 'star') || empty($message_id) || !is_user_logged_in() || !bp_core_can_edit_settings()) {
            wp_send_json_error(array('message' => 'Invalid request or insufficient permissions.'));
            return;
        }
    
        $result = bp_messages_star_set_action(array(
            'action' => $star_status,
            'message_id' => $message_id,
            'bulk' => $bulk,
            'user_id' => $displayed_user_id
        ));
    
        if ($result) {
            wp_send_json_success();
        } else {
            wp_send_json_error(array('message' => 'Failed to update message status.'));
        }
    }
    
    add_action('wp_ajax_wbcom_custom_buddypress_action', 'wbcom_custom_buddypress_ajax_handler');
    

    AJAX Request Adjustments like this

    jQuery.ajax({
        url: ajaxurl,
        type: 'POST',
        data: {
            'action': 'wbcom_custom_buddypress_action',
            'displayed_user_id': displayedUserId, // Include if available
            'message_id': messageId,
            'star_status': starStatus,
            // Additional data...
        },
        success: function(response) {
            // Handle success
        },
        error: function(error) {
            // Handle error
        }
    });
    

    We can suggest modifying the bp_legacy_theme_ajax_messages_star_handler() function to handle the displayed user ID and use the logged-in user ID as a fallback.

    function bp_legacy_theme_ajax_messages_star_handler() {
        if ( false === bp_is_active( 'messages', 'star' ) || empty( $_POST['message_id'] ) ) {
            return;
        }
    
        // Check nonce.
        check_ajax_referer( 'bp-messages-star-' . (int) $_POST['message_id'], 'nonce' );
    
        // Check capability.
        if ( ! is_user_logged_in() || ! bp_core_can_edit_settings() ) {
            return;
        }
    
        // Get the displayed user ID or fallback to the logged-in user ID.
        $user_id = isset($_POST['displayed_user_id']) && !empty($_POST['displayed_user_id']) 
                   ? (int) $_POST['displayed_user_id'] 
                   : get_current_user_id();
    
        if ( true === bp_messages_star_set_action( array(
            'action'     => $_POST['star_status'],
            'message_id' => (int) $_POST['message_id'],
            'bulk'       => ! empty( $_POST['bulk'] ) ? true : false,
            'user_id'    => $user_id  // Use the determined user ID
         ) ) ) {
            echo '1';
            die();
        }
    
        echo '-1';
        die();
    }
    
    John
    Participant

    The issue I’m facing is related to integrating BuddyPress into my theme. I’ve relocated the entire Messages component to a custom page that isn’t the default BuddyPress page. When users click on the Star and Unstar buttons, the functionality doesn’t work as intended. This is because it is loaded via AJAX using the bp_legacy_theme_ajax_messages_star_handler function, and this function calls bp_messages_star_set_action with the default user ID being the displayed user ID, You know, the bp_displayed_user_id() function doesn’t recognize the displayed user ID when called through AJAX.

    It would be more appropriate to change bp_displayed_user_id() to bp_loggedin_user_id() in this context 🙂

    I acknowledge that I could rewrite the code, but it’s preferable to maintain everything in its default state.

    Thank you.

    #332926
    John Simpson
    Participant

    Now updated Buddypress to v12.2 ……..Issue still there.

    #332919
    John Simpson
    Participant

    Wordpress v6.4.2
    Buddypress v12.1.1
    BP Classic v1.2.0

    Page Builder by SiteOrigin
    Theme SiteOrigin Corp

    #332917
    teslavolt
    Participant

    Hi @imath,

    I have a similar / related issue. I’m using Restrict Content Pro’s registration page with the latest Buddypress version (12.1.1) on a staging site and my registration page broke. It told me “Member registration is currently not allowed”, even if I disable the buddypress plugin.

    I tried the gist you posted https://gist.github.com/imath/c5c34feb5d3c9b3070f7a11bc339f103 in my child theme’s functions.php but the registration page still does not work. Any ideas?

    *Update* – I read through the earlier post and found the first workaround – going to Buddypress Settings -> URLs, but did not see any option to change the register slug. I had to briefly turn on wordpress general settings “Anyone can register” so that more options would appear in “URLs”. I was able to set the slug to something else like ‘sign-in’ and that seemed to allow my RCP registration to function again.

    Just to check, I disabled “Anyone can register”. Seems like the BP slug change stuck and my RCP registration is operational.

    #332912
    Varun Dubey
    Participant
    #332911
    markus150973
    Participant

    Hi all,
    I am German and ma English is not the best, but I try to discribe my problem as good as possible. But a small warning about my self: I have no idea about coding and I love plug’n’play!

    My site is : https://pinselcrew.de/

    I tried to start a forum with bbpress and buddypress. It worked perfectly together until last week. I got an email from my site that told me about a big problem. The memberlist was empty and the forum was totaly broken. So I asked my hoster for a backup.
    When I startet the debug mode, it told me that there is an error in the bbpress code that points to buddypress. After I deactivatet BuddyPress everything was fine again. So I deinstalled and installed it again. But the error is the same.

    Maybe aomeone has an idea. The first members really loved BuddyPress and now the miss it!

    Best regards from Hamburg

    Markus
    __________________________________________________
    This is the mail I received:

    Aktives Theme: Astra (Version 4.6.3)
    Aktuelles Plugin: bbPress (Version 2.6.9) PHP-Version 7.4.33 Fehler-Details ============== Ein Fehler vom Typ E_ERROR wurde in der Zeile 229 der Datei /www/htdocs/w01d4e65/pinselcrew.de/wp-content/plugins/bbpress/includes/extend/buddypress/members.php verursacht. Fehlermeldung: Uncaught Error: Call to undefined function bp_core_get_user_domain() in /www/htdocs/w01d4e65/pinselcrew.de/wp-content/plugins/bbpress/includes/extend/buddypress/members.php:229
    Stack trace:
    #0 /www/htdocs/w01d4e65/pinselcrew.de/wp-content/plugins/bbpress/includes/extend/buddypress/members.php(100): BBP_BuddyPress_Members->get_profile_url(131)
    #1 /www/htdocs/w01d4e65/pinselcrew.de/wp-includes/class-wp-hook.php(324): BBP_BuddyPress_Members->get_user_profile_url(131)
    #2 /www/htdocs/w01d4e65/pinselcrew.de/wp-includes/plugin.php(205): WP_Hook->apply_filters(131, Array)
    #3 /www/htdocs/w01d4e65/pinselcrew.de/wp-content/plugins/bbpress/includes/core/abstraction.php(471): apply_filters(‘bbp_pre_get_use…’, 131)
    #4 /www/htdocs/w01d4e65/pinselcrew.de/wp-content/plugins/bbpress/includes/users/template.php(560): bbp_maybe_intercept(‘bbp_pre_get_use…’, Array)
    #5 /www/htdocs/w01d4e65/pinselcrew.de/wp-content/plugins/bbpress/includes/admin/users.php(260): bbp_get_user_profile_url(131)
    #6 /www/htdocs/w01d4e65/pinselcrew.de

    #332900
    Varun Dubey
    Participant

    @puresaian To mention all group members simultaneously, you must implement a custom solution. This could be a special shortcode or command that automatically translates into individual mentions for all group members when used by the admin.

    
    /**
     * Handles the custom mention "@everyone" within BuddyPress groups.
     * When @everyone is used in a group's post or comment, it replaces it with mentions of all group members.
     */
    function wbcom_custom_everyone_mention_handler( $content ) {
        // Check if BuddyPress is loaded and @everyone is used in the content
        if ( function_exists( 'groups_get_current_group' ) && strpos( $content, '@everyone' ) !== false ) {
            // Get the current group details
            $group = groups_get_current_group();
    
            // Proceed only if we are in a group context
            if ( $group ) {
                // Fetch all members of the group
                $group_members = groups_get_group_members( array( 'group_id' => $group->id ) );
                $mentions = array();
    
                // Loop through each member to build the mentions array
                foreach ( $group_members['members'] as $member ) {
                    $mentions[] = '@' . $member->user_nicename; // Prepares the mention syntax for each member
                }
    
                // Replace @everyone in the content with the individual member mentions
                $content = str_replace('@everyone', implode(' ', $mentions), $content);
            }
        }
    
        // Return the modified (or unmodified, if no changes were made) content
        return $content;
    }
    
    // Add filters to apply the custom mention handler in different BuddyPress content types
    add_filter( 'the_content', 'wbcom_custom_everyone_mention_handler' ); // For regular WordPress content
    add_filter( 'bp_activity_new_update_content', 'wbcom_custom_everyone_mention_handler' ); // For new BuddyPress activity updates
    add_filter( 'bp_activity_comment_content', 'wbcom_custom_everyone_mention_handler' ); // For comments on BuddyPress activities
    
    

    It’s not a tested code; it’s just giving implementation directions.

    #332899
    Varun Dubey
    Participant

    @investbuddy123 Based on your description of issues with BuddyPress on your WordPress site, you’re encountering problems with group updates and public messaging functionalities.

    Here is a step-by-step guide to debug the issue:

    Check for Plugin Conflicts: Deactivate all plugins except BuddyPress and BP Classic. If the issue is resolved, reactivate each plugin individually to identify the conflicting plugin.

    Theme Compatibility: You’ve tried switching to the Twenty-Three theme with no success, which is good. It rules out theme-specific issues.

    Inspect JavaScript Errors: Use the browser’s Developer Tools (usually accessible by pressing F12) to check for JavaScript errors in the Console tab. JavaScript issues often cause features like loading updates or activating functions to fail.

    Server and PHP Error Logs: Check your server and PHP error logs for any relevant errors. Your hosting provider can assist you in accessing these if you’re unsure how.

    Test on a Staging Site: If possible, clone your site to a staging environment. This allows you to test without affecting your live site.

    Cache and Optimization Plugins: If you use caching or optimization plugins, clear the cache and temporarily disable them to see if they are causing the issue.

    Check for Custom Code: If you have any custom code (like snippets in your theme’s functions.php file or a custom plugin), comment to see if it is causing the issue.

    #332895
    Ceraus
    Participant

    Hello there!

    I’m unsure why, but Buddypress is removing the footer from pages. I only have BuddyXPro and Buddypress activated, the footer returns on deactivation of Buddypress, but is removed again upon activation. Would anyone have any idea what to do to keep the footer?

    Thank you,
    Chris

    #332886
    kioubizin
    Participant

    Hello,

    Since I am also using BuddyPress and bbPress on my website, I installed the BP Classic as guided.

    When I activate the BP Classic it fix my issue with bbPress.

    However, it creates another issue now!

    This is how my widgets area looks like in admin when BP Classic is disactivated – http://tinyurl.com/ymrpz5sk

    And this is how it looks like when BP Classic is activated – http://tinyurl.com/ysmcw22f

    As you can see, it disables all my available widget areas and widget settings once the BP Classic is activated.

    This BB Classic fixed my issue with bbPress but creates another issue and it’s impossible for me to manage my widgets when the plugin is activated!

    #332884
    hossin0241
    Participant

    Thank you for creating this topic

    I think, if possible, that the system of historiography
    Change BuddyPress to the default WordPress system, it’s better
    (Things like choosing the date of birth and…)

    So that users who use other history systems can also benefit from it

    #332881
    emaralive
    Moderator

    Hi,

    You should be able to find a remedy at the following post:

    https://buddypress.org/support/topic/buddypress-12-1-1-maintenance-security-release/#post-332831

    kioubizin
    Participant

    Hello,

    While trying to access users from admin menu, I am getting a fatal error and when enabling the debug mode, I am getting this error message:

    Fatal error: Uncaught Error: Call to undefined function bp_core_get_user_domain() in /home/islandbnb/public_html/wp-content/plugins/bbpress/includes/extend/buddypress/members.php:229 Stack trace: #0 /home/islandbnb/public_html/wp-content/plugins/bbpress/includes/extend/buddypress/members.php(100): BBP_BuddyPress_Members->get_profile_url(2) #1 /home/islandbnb/public_html/wp-includes/class-wp-hook.php(324): BBP_BuddyPress_Members->get_user_profile_url(2) #2 /home/islandbnb/public_html/wp-includes/plugin.php(205): WP_Hook->apply_filters(2, Array) #3 /home/islandbnb/public_html/wp-content/plugins/bbpress/includes/core/abstraction.php(471): apply_filters('bbp_pre_get_use...', 2) #4 /home/islandbnb/public_html/wp-content/plugins/bbpress/includes/users/template.php(560): bbp_maybe_intercept('bbp_pre_get_use...', Array) #5 /home/islandbnb/public_html/wp-content/plugins/bbpress/includes/admin/users.php(260): bbp_get_user_profile_url(2) #6 /home/islandbnb/public_html/wp-includes/class-wp-hook.php(324): BBP_Users_Admin->user_row_actions(Array, Object(WP_User)) #7 /home/islandbnb/public_html/wp-includes/plugin.php(205): WP_Hook->apply_filters(Array, Array) #8 /home/islandbnb/public_html/wp-admin/includes/class-wp-users-list-table.php(520): apply_filters('user_row_action...', Array, Object(WP_User)) #9 /home/islandbnb/public_html/wp-admin/includes/class-wp-users-list-table.php(415): WP_Users_List_Table->single_row(Object(WP_User), '', '', 0) #10 /home/islandbnb/public_html/wp-admin/includes/class-wp-list-table.php(1709): WP_Users_List_Table->display_rows() #11 /home/islandbnb/public_html/wp-admin/includes/class-wp-list-table.php(1636): WP_List_Table->display_rows_or_placeholder() #12 /home/islandbnb/public_html/wp-admin/users.php(814): WP_List_Table->display() #13 {main} thrown in /home/islandbnb/public_html/wp-content/plugins/bbpress/includes/extend/buddypress/members.php on line 229

    adm2024in
    Participant

    I’m currently working on an Arabic version of our BuddyPress website.

    In order to create a complete user experience in Arabic, I’d like to duplicate some important BuddyPress-related pages, such as “Members”, “Activity”, “Groups”, “User Profile” and “Forums”, and translate them into Arabic, the pages must be displayed in Arabic, but the provider link displays it in English, when I translate the page, it translates the French version too.

    However, I’m encountering difficulties in implementing this duplication, and am seeking your assistance in guiding me on the best approach to take. Could you please provide me with detailed instructions or relevant resources to help me accomplish this task successfully?

    I would like to thank you in advance for your valuable assistance. Your expertise will be of great importance in ensuring the success of this initiative.

    JSanke
    Participant

    WP version 6.4.2, BuddyPress v. 12.1.1 and BP classic 1.2.0 site is learn.knityourdog.com (login required) running reservoir/fluida theme.

    Have 3 groups set up so far, all show “loading group updates, please wait” and nothing ever loads. Private messaging between members is working, public messaging is not. Cannot even click to activate the function.
    No change when using Twenty Twenty-Three theme. Same problems exactly.
    Have never had this issue on a BP site before and this is my 4th. Unsure how to remedy.

Viewing 25 results - 726 through 750 (of 69,210 total)
Skip to toolbar