Search Results for 'custom activity page'
-
Search Results
-
Topic: Problem when deleting terms
Hi,
I’ve run into an issue that appears to be caused by BuddyPress when deleting terms (categories, tags, and custom taxonomies) in WordPress admin.
When I delete a term in wp-admin (for example a category or a custom taxonomy term), I get the following error message:
“An error occurred while processing your request. Please try again later.”
However, after reloading the page, the term is actually deleted successfully.
– Deleting posts and comments works without any issues
– The problem affects:
– Categories (category)
– Tags (post_tag)
– Custom taxonomies (e.g. from PublishPress Series)
– No errors are logged in:
– wp-content/debug.log
– Apache error logWhen deleting the same term using WP-CLI, everything works perfectly:
bash wp term delete category <term_id>
– No errors
– Term is deleted correctlyI disabled all plugins and then re-enabled them one by one. The issue only occurs when BuddyPress is active. With BuddyPress deactivated, term deletion works normally in wp-admin (no error message)
In our system we use PublishPress Series, which registers a custom taxonomy called series. We have currently ~440 terms in this taxonomy
– The number is continuously growing
– The issue started appearing when the number of terms became relatively largeThis might indicate a scaling issue or something triggered by higher term counts.
– The term is deleted successfully via wp_delete_term
– Something in BuddyPress interferes with the response afterward
– Possibly an issue with AJAX response (invalid JSON, unexpected output, etc.)Has anyone seen this behavior before?
Is there anything in BuddyPress that hooks into term deletion (e.g. activity, notifications, or other components) that could break the admin AJAX response without triggering a PHP error?
Could this be related to the number of terms in a taxonomy?
We have also a similar problem when creating terms. No error messages in wp-admin but when clicking create it doesn’t look like that the term has been created. But when reloading the page the term is there.
Any pointers on where in BuddyPress this might happen would be greatly appreciated.
– WordPress: latest version
– BuddyPress: latest version
– PHP: 8.3 (PHP-FPM)Thanks!
Hello everyone,
I’m trying to create a simple custom theme to override the BuddyPress (Nouveau) registration page, but I’m consistently running into a White Screen of Death (WSOD). I’ve been troubleshooting for a while and would appreciate any help you can offer.
My Goal:
To create a custom theme that overrides register.php from the BP Nouveau template pack.My Environment:
OS: Windows
Local Development Tool: DevKinsta
Plugin: BuddyPress (latest version)
The Problem:
When I activate my custom theme, I get a WSOD when trying to access the site (e.g., mysite.local/register/).Here is a summary of the troubleshooting steps I have already tried:
Enabled WP_DEBUG: I have set WP_DEBUG, WP_DEBUG_LOG, and WP_DEBUG_DISPLAY to true in my wp-config.php. However, no errors are ever displayed on the screen or written to the debug.log file. The page is just completely blank.
Checked for PHP Errors: I initially had parse errors (an extra } bracket) in my functions.php and register.php files. These have been found and corrected.
Checked for BOM: I have verified with my code editor (VS Code) that all my theme files are saved with UTF-8 encoding and do not have a Byte Order Mark (BOM).
Reset Permalinks: I have gone to Settings > Permalinks and clicked “Save Changes” multiple times to rebuild the rewrite rules.
Theme Deactivation Test: When I rename my theme’s folder to force WordPress to deactivate it, I can access wp-admin again. This confirms the issue is within my theme’s code.
File Permissions: I received a security warning that /wp-content/ was too writeable. I have reset the permissions for my entire site folder on my Windows machine to ensure they are not too permissive.
My Theme Structure and Code:
My theme is very simple.
1. Directory Structure for the Override:
wp-content/themes/kfluxtheme/buddypress/members/register.php
(The register.php file is an exact, unmodified copy from wp-content/plugins/buddypress/bp-templates/bp-nouveau/buddypress/members/)/* Theme Name: K-Flux Theme Author: My Name Version: 1.0 */<?php /** * Theme functions and definitions. */ if ( ! function_exists( 'kfluxtheme_setup' ) ) { /** * Basic theme setup. */ function kfluxtheme_setup() { // Add support for BuddyPress (ESSENTIAL) add_theme_support( 'buddypress' ); // Let WordPress manage the document title. add_theme_support( 'title-tag' ); // Enable support for Post Thumbnails. add_theme_support( 'post-thumbnails' ); } } add_action( 'after_setup_theme', 'kfluxtheme_setup' ); /** * Enqueue scripts and styles. */ function kfluxtheme_enqueue_scripts() { wp_enqueue_style( 'kfluxtheme-style', get_stylesheet_uri(), array(), '1.0' ); } add_action( 'wp_enqueue_scripts', 'kfluxtheme_enqueue_scripts' );Despite all these steps, the WSOD persists when my theme is active. Since WP_DEBUG is not showing any errors, I’m running out of ideas on how to debug this further.
Has anyone encountered a similar issue with DevKinsta or have any suggestions for what I might be missing?
Thanks in advance for any help.
WP: 6.7.1
BP: 14.3.1
BPGE: 3.7.0
Theme : BuddyBoss with a custom child themeBefore version 3.7.0 of the buddypress-groups-extras plugin, I could reorder the group tabs, even the Home/Activity. I used this to put Pages on top (above Activity) to ensure it was the landing page for the group.
Activity is now hard coded as the first tab in core/templates.php of BPGE as explained in Emaralive’s response to my previous request https://buddypress.org/support/topic/activity-tab-cannot-be-moved-in-manage-page-general-settings-anymore/How could I change the default group landing pages to Pages instead of Activity?
Hi,
I am facing an issue with the media upload option in BuddyPress on my Community Guidelines page. When I try to upload a media file:
The “Choose File” option appears, and the file successfully uploads in the interface.
However, the file suddenly disappears, and I get a red error message saying, “Please choose some content to post.”Steps I’ve Taken to Fix It:
-
Tried using custom code to resolve the issue—no success.
Cleared cache from the hosting panel and WordPress dashboard.
Checked for plugin conflicts by disabling all other plugins, but the issue still persists.
Tested on different themes—the issue remains.Moreover strange thing is, Media upload works fine if I go to My Profile → Media and post on my feed.
The issue only happens inside Groups—media upload is not working on group posts.
I have also reviewed some BuddyPress articles where users reported the same issue, but I didn’t find a resolution.
i.e, https://buddypress.org/support/topic/cant-upload-media-from-sitewide-activity-stream/As I am handling a community website, I urgently need this feature to work.
Please provide guidance on how to fix this issue.My Site’s URL: edit: link removed
Thank you!WP: 6.7.1
BP: 14.3.1
Theme : BuddyBoss with a custom child themeSince we update to 14.3 we cannot change the Activity tab order in the manage Page general setting anymore
When we create a group, the default page is Activity.
Previously it was possible to change it to any other tab in Manage Page General Setting, but not anymore.
While I can change the place of the other tabs (Pages; Members, etc.) I cannot move the Activity any more, i.e. I cannot grab the Activity button while I can still grab and move the others.If I edit an old group where I changed the tab default to something else than Activity, I can still change the other tabs but I cannot grab the Activity and therefore I cannot change its order.
Could someone help me on where to look at ? I’m clueless at this point.
I tried on Safari Google Chrome, Firefox and observe the same behaviour.
Thanks for your help
Dominique
WP 6.6.2, BP 14.2.1, Divi theme.
I added a bunch of WordPress users to my site from a csv file using the Import and export users and customers plugin. Worked well. But those users couldn’t figure out how to make friend requests, since they couldn’t “see” the other users that they could ask. After some fumbling through this forum and googling, I came across the “/members” slug. I seemed like exactly what I needed, a list of members with a button to send a friend request to each one. The only problem was that it didn’t show all the users. More ressearch found this post from 10 years ago. Seems the issue was/is that it only shows those users who have had some BuddyPress activity recorded. But since these were mostly new users, most had no activity. So I wrote a little bp-custom.php file containing:
function make_all_users_active() { $users = get_users(); // repete_log(print_r($users, true), __FILE__, __LINE__); foreach($users as $user) { if (strlen(bp_get_user_last_activity($user->ID)) == 0) { // repete_log(sprintf("bp_update_user_last_activity(%s)", $user->ID), __FILE__, __LINE__); echo $user->ID . "<br>"; bp_update_user_last_activity($user->ID); } } } add_action ('wp_loaded', 'make_all_users_active');This solved the problem of not showing all the other BuddyPress members, but as far as I can tell, I’ve now got to tell all the users that if they’re interested in making friend connections, they have to go to the address bar, and type /members right after the domain name. That seems ridiculous! I guess I could add a page containing a link to that slug that they could click, but it would be nicer if I could make a page they could find as one of the site’s pages that would display the information from that slug, without having to click a link. Better still would be to be able to customize the BuddyPress drop-down menu to add an item for “All Members” that would display the slug’s contents…
Hi
Is it possible to add the Activity Feed in a custom location?
I find the Activity page quite restrictive and would like to add a feed to a custom page via a shortcode.
I can gt the feed to load like this – however it seems to be missing styling and when clicking comment it redirects me.
Is there a better way to do this?
function custom_shortcode_activityfeed() { ob_start(); if ( function_exists( 'bp_has_activities' ) ) { bp_get_template_part( 'activity/activity-loop' ); } $output .= ob_get_clean(); return $output; } add_shortcode( 'custom_activityfeed', 'custom_shortcode_activityfeed' );Hi everyone,
I’m working on customizing my BuddyPress site and would like to change the text that says “posted an update in the group” on the activity page. Specifically, I want to replace the word “group” with “Teams.”
Could someone guide me on which file I need to edit to make this change? Any tips on best practices for modifying this would also be appreciated to ensure I don’t break any future updates.
Thanks in advance!
Best,
Topic: custome query
i want to get only 2 comments , on load of activity page . wich i really get using my code
“add_filter(‘bp_use_legacy_activity_query’, function ($value, $method, $args) {
if ($method == “BP_Activity_Activity::get_activity_comments”) {
return true;
}
}, 10, 3);add_filter( ‘bp_activity_comments_user_join_filter’, function( $value, $activity_id, $left, $right, $spam = ‘ham_only’ ) {
// Modify the SQL query to fetch only two comments
global $wpdb, $bp;
$bp = buddypress();$xprofile_active = function_exists(‘bp_is_active’) && bp_is_active( ‘xprofile’ );
// Initialize fullname related variables
$fullname_select = $fullname_from = $fullname_where = ”;// Select the user’s fullname with the query if XProfile is active and user has filled the field.
if ( $xprofile_active ) {
if ( bp_has_profile() ) {
// Get the field value if user has filled it.
$field_id = 1; // Modify this according to your field ID.
$field_value = bp_get_profile_field_data( ‘field=’ . $field_id );
if ( !empty( $field_value ) ) {
$fullname_select = “, pd.value as user_fullname”;
$fullname_from = “, {$bp->profile->table_name_data} pd “;
$fullname_where = “AND pd.user_id = a.user_id AND pd.field_id = $field_id”;
}
}
}// Don’t retrieve activity comments marked as spam.
if ( ‘ham_only’ == $spam ) {
$spam_sql = ‘AND a.is_spam = 0’;
} elseif ( ‘spam_only’ == $spam ) {
$spam_sql = ‘AND a.is_spam = 1’;
} else {
$spam_sql = ”;
}// Modify the SQL query to fetch only two comments
$sql = $wpdb->prepare( “SELECT a.*, u.user_email, u.user_nicename, u.user_login, u.display_name{$fullname_select}
FROM {$bp->activity->table_name} a, {$wpdb->users} u{$fullname_from}
WHERE u.ID = a.user_id {$fullname_where}
AND a.type = ‘activity_comment’ {$spam_sql}
AND a.item_id = %d
AND a.mptt_left > %d
AND a.mptt_left < %d
ORDER BY a.date_recorded ASC
LIMIT 2″,
$activity_id, $left, $right );return $sql;
}, 10, 5 );”but it give me also count 2 , can i get original count.
means , any activity has 10 comment then it display only 2 but give count 10
i Have this link now: https://domain.com/member/johndoe/activity/512/
but need this: https://domain.com/512/how i can do that by some php snippet? pls help
Something like this? but its bad code i mean
function custom_activity_link($activity_id = false) { global $bp; if (!$activity_id) { $activity_id = bp_get_activity_id(); } return home_url('/' . $activity_id . '/'); } function change_buddypress_activity_permalink() { global $bp; $bp->activity->root_slug = 'activity'; add_rewrite_rule('^([0-9]+)/?$', 'index.php?pagename=activity&p=$matches[1]', 'top'); } add_action('bp_init', 'change_buddypress_activity_permalink', 2); add_filter('bp_get_activity_thread_permalink', 'custom_activity_link', 10, 2);

I have a custom template page that I’ve added specific bp-activities and its comments (pulled some code from the activity-loop).
In Buddypress v11.4.3, everything was working fine, the activity displays and comments + reply functionality works – click on a reply and the .ac-form moves to selected reply/comment and it nests it as expected.
Since Buddypress 12, replies no longer work. I think it’s because the Buddypress scripts no longer load on NON-buddypress pages. I tried enqueueing Buddypress scripts myself using a function:
but just loading the scripts is not enough. When I replaced buddypress-activity.js with my own version to debug, I noticed that BP_Nouveau returns as ‘undefined’ and so none of the script functionality would run.
I’m probably missing something really simple but how can I load Buddypress core scripts or styles in my own custom wordpress template?