that is presuming you have run the normal tests
Plugins
Deactivate all but bbpress and see if this fixes. if it does, re-enable one at a time to see which is causing the error.
Themes
If plugins don’t pinpoint the problem, as a test switch to a default theme such as twentyfifteen, and see if this fixes.
hello
I have this same problem
I did import bbpress data from old site to my new site but now i can’t open Admin Replies Page and get “503 – Service Unavailable error” , but i can access Topics page, Forums page, and all settings of the plugin.
please help me
its so emergency for me
bbPRess-wordpress is really slow on my site. 7 to 10 seconds loading the main forum page. Submitting a new topic can go over 20 sec. 75% of that time is waiting for a reply…
It’s hosted on a VPS and when I monitor the CPU and RAM memory, it is always under the max, CPU runs at 50-70% on a request and ram stays around 70% used.
It seems to me that the requests to mySql takes a long time to execute.
We have 11500 topics and 75000+ replies. It was a phpBB forum that has been converted to bbPRess.
What can I do to improve performances?
Managed to sort this out myself. We are using BuddyPress Registration Options plugin and I missed the check box: Only registered or approved members can view BuddyPress/bbPress pages (Private Network).
I need a drink ha…
Hello,
BBPress is running great on this site but if a visitor is a guest and clicks a topic to view the content, they are redirected to the home page. We are using WordPress pages with shortcodes to manage the forum.
If you view the sample forum and click the I’m In topic it goes to the home page as guests. We need guests to be able to see the topic info to decide if they want to join.
Any info would be great, here is the page:
<a href=”http://www.raptureintheairnow.com/forums/main-forum/”
Thank you.
ok, try this plugin
bbp blacklist checker
once activated go to tools>bbp blacklist checker
This lets you switch off the code that is causing the issue.
It’s just a bit of testing code, not intended for permanent live use, but may help confirm if it’s bbpress or something behind that is causing the issue.
Try it for both anew post and an edited one
Hi guys,
Hope this doesn’t come across as a really stupid question, or should I say, hope this doesn’t come across as a question that shows my stupidity……
You have me interested in the name “bbpress”. Can you shed some light on where the name came from and whether it means anything in particular?
Thanks in advance.
Yes I got that far, not sure how to use modify the following code just for that sepecific category/forum This is the code for the discussion page
<?php
/**
* [g1_bbp_forums] shortcode callback function.
*
* @param array $atts
* @param string $content
* @return string
*/
function g1_bbp_forums_shortcode( $atts, $content ) {
/* We need a static counter to trace a shortcode without the id attribute */
static $counter = 0;
$counter++;
extract( shortcode_atts( array(
‘id’ => ”,
‘class’ => ”
), $atts, ‘g1_bbp_forums’ ) );
// Compose final HTML id attribute
$final_id = strlen( $id ) ? $id : ‘g1-bbp-forums-‘ . $counter;
// Compose final HTML class attribute
$final_class = array(
‘g1-bbp-forums’,
);
$final_class = array_merge( $final_class, explode( ‘ ‘, $class ) );
// Note: private and hidden forums will be excluded via the
// bbp_pre_get_posts_normalize_forum_visibility action and function.
$query = new WP_Query( array(
‘post_type’ => bbp_get_forum_post_type(),
‘post_parent’ => $settings[‘parent_forum’],
‘post_status’ => bbp_get_public_status_id(),
‘posts_per_page’ => get_option( ‘_bbp_forums_per_page’, 50 ),
‘ignore_sticky_posts’ => true,
‘no_found_rows’ => true,
‘orderby’ => ‘menu_order title’,
‘order’ => ‘ASC’
) );
if ( ! $query->have_posts() ) {
return ”;
}
// Start output buffer
ob_start();
?>
<div class=”<?php echo implode( ‘ ‘, array_map( ‘sanitize_html_class’, $final_class ) ); ?>”>
<div class=”g1-collection g1-collection–grid g1-collection–one-third g1-collection–simple”>
<?php while ( $query->have_posts() ) : $query->the_post(); ?>
<li class=”g1-collection__item”>
<article>
<?php if ( has_post_thumbnail() ): ?>
<figure class=”entry-featured-media”>
post->ID ); ?>”>
<?php the_post_thumbnail( ‘g1_one_third’ ); ?>
</figure>
<?php else: ?>
<?php echo do_shortcode( ‘[placeholder icon=”camera” size=”g1_one_third”]’ ); ?>
<?php endif; ?>
<div class=”g1-nonmedia”>
<div class=”g1-inner”>
<header class=”entry-header”>
<h3 class=”entry-title”>
post->ID ); ?>”><?php bbp_forum_title( $query->post->ID ); ?>
</h3>
<p class=”entry-meta g1-meta”>
<span><?php _e( ‘Topics’, ‘bbpress’ ); ?>: <?php bbp_forum_topic_count( $query->post->ID ); ?></span>
<span><?php bbp_show_lead_topic() ? _e( ‘Replies’, ‘bbpress’ ) : _e( ‘Posts’, ‘bbpress’ ); ?>: <?php bbp_show_lead_topic() ? bbp_forum_reply_count( $query->post->ID ) : bbp_forum_post_count( $query->post->ID ); ?></span>
</p>
</header>
<div class=”entry-summary”>
<?php the_excerpt(); ?>
</div>
</div>
</div>
</article>
<?php endwhile; ?>
</div>
</div>
<?php
// Reset the $post global
wp_reset_postdata();
// Return and flush the output buffer
return ob_get_clean();
}
add_shortcode( ‘g1_bbp_forums’, ‘g1_bbp_forums_shortcode’ );
ok, now I can see – this is well beyond free help, buy suggest you start by looking at modifying
wp-content/plugins/bbpress/templates/default/bbpress/content-archive-forum.php
create a directory on your theme called ‘bbpress’
ie wp-content/themes/%your-theme-name%/bbpress
where %your-theme-name% is the name of your theme
find
wp-content/plugins/bbpress/templates/default/bbpress/content-archive-forum.php
Make a copy of this file, and put in in the directory called bbpress that you created above, so you end up with
wp-content/themes/%your-theme-name%/bbpress/content-archive-forum.php
bbPress will now use this template instead of the original
and you can amend this
for anyone finding this topic
I kicked this code around to improve it and also stop the 404 error when a participant trashes a topic, so latest version is
/*Customize the BBPress roles to allow Participants to trash topics*/
add_filter( 'bbp_get_caps_for_role', 'ST_add_role_caps_filter', 10, 2 );
function ST_add_role_caps_filter( $caps, $role ){
// Only filter for roles we are interested in!
if( $role == bbp_get_participant_role() ) {
//only change delete topics
$caps ['delete_topics']= true ;
}
return $caps;
}
/*then only allow participants to trash their own topics*/
add_filter( 'bbp_map_topic_meta_caps', 'ST_tweak_trash_meta_caps', 11, 4 );
function ST_tweak_trash_meta_caps( $caps, $cap, $user_id, $args ){
// apply only to delete_topic
if ( $cap == "delete_topic" ){
// Get the post
$_post = get_post( $args[0] );
if ( !empty( $_post ) ) {
// Get caps for post type object
$post_type = get_post_type_object( $_post->post_type );
// Add 'do_not_allow' cap if user is spam or deleted
if ( bbp_is_user_inactive( $user_id ) ) {
$caps[] = 'do_not_allow';
// Moderators can always edit forum content
} elseif ( user_can( $user_id, 'moderate' ) ) {
$caps[] = 'moderate';
// User is author so allow edit if not in admin
} elseif ( user_can( $user_id, 'participate' ) && ( (int) $user_id === (int) $_post->post_author ) ) {
$caps = array();
// Unknown so do not allow
} else {
$caps[] = 'do_not_allow';
}
}
}
// return the capabilities
return $caps;
}
//then redirect to the forum after trashing topic
add_action('bbp_template_redirect', 'ST_trash_topic_check', 8);
//check if topic has been trashed by author and show forum if it has
function ST_trash_topic_check() {
$topic_slug = get_option( '_bbp_topic_slug') ;
//quick check if we need to do this function, so bail if not a topic
if (strpos($_SERVER['REQUEST_URI'], $topic_slug) == FALSE) return ;
$forum_slug = bbp_get_root_slug() ;
//if check is set (ie we prefix forums with the forum slug) then part 1 will be forum slug and part 2 will be topic slug, if not part 1 will be topic slug
$check = bbp_include_root_slug() ;
$link = explode('/',$_SERVER['REQUEST_URI']);
//next we need the topic id (post id) of the topic so we need to check if it is a topic and if so, find the topic id
if (is_user_logged_in() && $check && $link[1] == $forum_slug && $link[2] == $topic_slug ) {
$post = bsp_get_page_by_slug( $link[3], OBJECT, 'topic' );
$login_check=1 ;
}
elseif (is_user_logged_in() && empty($check) && $link[1] === $topic_slug) {
$post = bsp_get_page_by_slug( $link[2], OBJECT, 'topic' );
$login_check=1 ;
}
//now we need to check if the topic has been trashed by author
if (!empty ($login_check) && $post->post_status == 'trash' && $post->post_author == get_current_user_id() ) {
$topic_id = $post->ID;
//then redirect to the forum we came from
$forum = bbp_get_forum_permalink (bbp_get_topic_forum_id ( $topic_id )) ;
wp_redirect ($forum) ;
exit ;
}
else return ;
}
I’ll add this function into my style pack plugin shortly
bbp style pack
I kicked this code around to improve it and also stop the 404 error when a participant trashes a topic, so latest version is
/*Customize the BBPress roles to allow Participants to trash topics*/
add_filter( 'bbp_get_caps_for_role', 'ST_add_role_caps_filter', 10, 2 );
function ST_add_role_caps_filter( $caps, $role ){
// Only filter for roles we are interested in!
if( $role == bbp_get_participant_role() ) {
//only change delete topics
$caps ['delete_topics']= true ;
}
return $caps;
}
/*then only allow participants to trash their own topics*/
add_filter( 'bbp_map_topic_meta_caps', 'ST_tweak_trash_meta_caps', 11, 4 );
function ST_tweak_trash_meta_caps( $caps, $cap, $user_id, $args ){
// apply only to delete_topic
if ( $cap == "delete_topic" ){
// Get the post
$_post = get_post( $args[0] );
if ( !empty( $_post ) ) {
// Get caps for post type object
$post_type = get_post_type_object( $_post->post_type );
// Add 'do_not_allow' cap if user is spam or deleted
if ( bbp_is_user_inactive( $user_id ) ) {
$caps[] = 'do_not_allow';
// Moderators can always edit forum content
} elseif ( user_can( $user_id, 'moderate' ) ) {
$caps[] = 'moderate';
// User is author so allow edit if not in admin
} elseif ( user_can( $user_id, 'participate' ) && ( (int) $user_id === (int) $_post->post_author ) ) {
$caps = array();
// Unknown so do not allow
} else {
$caps[] = 'do_not_allow';
}
}
}
// return the capabilities
return $caps;
}
//then redirect to the forum after trashing topic
add_action('bbp_template_redirect', 'ST_trash_topic_check', 8);
//check if topic has been trashed by author and show forum if it has
function ST_trash_topic_check() {
$topic_slug = get_option( '_bbp_topic_slug') ;
//quick check if we need to do this function, so bail if not a topic
if (strpos($_SERVER['REQUEST_URI'], $topic_slug) == FALSE) return ;
$forum_slug = bbp_get_root_slug() ;
//if check is set (ie we prefix forums with the forum slug) then part 1 will be forum slug and part 2 will be topic slug, if not part 1 will be topic slug
$check = bbp_include_root_slug() ;
$link = explode('/',$_SERVER['REQUEST_URI']);
//next we need the topic id (post id) of the topic so we need to check if it is a topic and if so, find the topic id
if (is_user_logged_in() && $check && $link[1] == $forum_slug && $link[2] == $topic_slug ) {
$post = bsp_get_page_by_slug( $link[3], OBJECT, 'topic' );
$login_check=1 ;
}
elseif (is_user_logged_in() && empty($check) && $link[1] === $topic_slug) {
$post = bsp_get_page_by_slug( $link[2], OBJECT, 'topic' );
$login_check=1 ;
}
//now we need to check if the topic has been trashed by author
if (!empty ($login_check) && $post->post_status == 'trash' && $post->post_author == get_current_user_id() ) {
$topic_id = $post->ID;
//then redirect to the forum we came from
$forum = bbp_get_forum_permalink (bbp_get_topic_forum_id ( $topic_id )) ;
wp_redirect ($forum) ;
exit ;
}
else return ;
}
I’ll add this function into my style pack plugin shortly
bbp style pack
this site only does this for the wordpress and bbpress sites.
I’ll take a look at the plugin above soon, but tied up with other stuff at the moment
Hello again, right well here’s a plugin that purports to do EXACTLY what I want… Except its for posts in WordPress, NOT for bbpress.
URL-Preview-Box
I feel like somebody here might know how to make this work in bbpress as well. I also feel like somebody must have already implemented this on their own forums and knows how to do it. Can anyone assist at all please? Thanks!
Yes AsynCRONousbbPress Subscriptions works out of-the-tin as described. But it turns a single email with 123 Bcc addressees into 123 single addressee emails, which breaks my ISP’s limit of 100 emails/hour. Sigh!
I have finally achieved my own plugin which hooks onto wp_mail() and which chops up outgoing emails into multiple emails with a configured maximum Bcc addressee limit. So with my ISP’s limit of 10 addressees, my 123 notifications get sent in 12 emails each with 10 addressees plus 1 with the last 3.
It works with all outgoing emails that supply the Bcc addresses in an array (as does bbPress) or a flat list (as does Subscribe2 for WP post notifications).
Code here.
Hi there, first of all, sorry if this is something everybody knows, i did try to google it but came up with only things that aren’t the same as what i’m looking for.
What i would like is for an image preview of some sort to come up within the post or reply, in bbpress, whenever somebody pastes a URL. Ideally it should only happen for the first URL in each post or reply, and ignore any subsequent URLs, but if that’s fiddly then just something that will generate previews for any URLs posted would be very helpful.
Here is an example of it not happening: https://yesbook.scot/forums/topic/the-greatest-argument-of-all/
That’s me posting an OP in my bbpress forum, and as you can see i pasted some text from a web page, and then a URL link to the page. Now what would be ideal is if the post also automatically showed a picture, drawn from the URL, inline within the bbprss post, in the same way that facebook pulls a picture in when you post a URL on their site.
Is there a plugin that does this, or some simple tweak i can make to the config files of the site to make this happen? I’m not totally ignorant of how to use php and CSS but for the sake of argument, please assume that i am, because it isn’t far from the truth!
Thanks in advance for any assistance you can provide.
It is currently WordPress version 5.1 and bbPress version 2.5.14-6684
I am using DI Business Responsive theme, though i don’t think that makes much difference for this particular question.
I have a need for the following to happen:
1.) New User is created in bbPress
2.) A Thread is automatically created inside one Forum (Private Forum) that is PRIVATE from all eyes but Admin and that new user
3.) If a Logged In User who is not Admin accesses the Private Forum, they will only see their own Private Thread. The Admin will be able to see all threads.
Can anyone point me in the direction of how this is possible?
I would like to sort the topics by the number of likes column on the admin edit screen.
This is what ive got:
<?php
// make columns sortable -------------------------------------------------
// define which columns to be sortable
add_filter( 'manage_edit-topic_sortable_columns', 'topic_likes_table_sorting' );
function topic_likes_table_sorting( $columns ) {
$columns['likes_count'] = 'likes_count';
return $columns;
}
// add sortable to meta key
add_action( 'pre_get_posts', 'likes_orderby' );
function likes_orderby( $query ) {
if ( ! is_admin() ){ return; }
$orderby = $query->get( 'orderby');
if ( 'likes_count' == $orderby ) {
$query->set('meta_key','bbpress_topic_like_button_like');
$query->set('orderby','meta_value_num');
}
}
I dont think there is a meta_key for favorites stored in the topic post_meta? I’m setting the number in the column by using the following:
$topic_id = bbp_get_topic_id($id);
$likes_count = bbp_get_topic_favoriters($topic_id);
I think the favorites are stored with the users metadata. So my best guess is that ill need to write a function that stores/updates the number of favorites inside the post meta. Then and only then can I sort the posts by that new metakey. Can anyone point me in the right direction with this?
Thank you!
I’m trying to import IPB database to bbPress with “Tools>Forums>Import Forums”.
But I always get a log that nothing is converted:
Conversion Complete
No reply_to parents to convert
No replies to convert
No tags to convert
No super stickies to stick
No stickies to stick
No topics to convert
No forum parents to convert
No forums to convert
No passwords to clear
No users to convert
Starting Conversion
Select Platform == Invision.
IP.Board version is v3.4.6.
How I could troubleshoot this? Where should I start at least?.
I’ve been doing a lot of research and I am wondering the same thing. The closest I have found was this:
Allow Participants to Trash / own Topics and Posts
However, that was posted 2 years ago and it seems the code doesn’t work anymore. Ironically, @robin-w it’s your modification xD. Would you mine dropping some insight as to why the code isn’t functioning properly anymore, please. 🙁
Hay. New here. I tried to create a theme from scracth using pure html php and etc
At first, it was normal. It functions normally and the UI is not as messed up as right now.
And now out of anything, it suddenly messed up. Checkout my website here if you wanna see it https://psikologipolda.com/konsul-online/
I tried uninstalling bbpress, tried using different way of calling the forums and it still doesn’t work. Try looking at the css and tweak it, still doesn’t change.
Any idea? or any place I should edit my code?
FYI the page only used:
the content.php (that is used as a template for any content including the forum)
and the custom template for that page only.php
My site has been suspended by my ISP twice in the last couple of days for ‘malicious activity’, which turns out to be breaching their new limit of 10 addressees per email. (Most of my forums currently have 123 subscribers.)
I have had to disable the sending emails for new topics entirely, until I have a solution.
Breaking up these emails is pretty essential as most ISPs are now imposing some limit on the number of addressees, although my ISPs limit of 10 must one of the lowest.
I have no indication that bbPress is going to address this, so I may have to develop something myself. In this thread a couple of approaches are mentioned. But before I start digging in to bbPress core, does anyone have any suggestions/pointers?
PS I am using GD bbpress Toolbox to format the emails and do not want interfere with that function.
I have not been able to delete bbpress. The reset tool does not work.
Hi,
we’re running bbpress and our users should be able to delete their own posts.
We’ve blocked the wordpress menu bar on top of the page after a user is logged in.
How is it possible to delete posts in the frontend without switching to the backend of wordpress?
Thanks,
Daniel
Hello,
I want to filter forum/topic subscribers using these filters
bbp_topic_subscription_user_ids
and
bbp_forum_subscription_user_ids
based on forum/topic ID.
But when I see the filter, it only passes
$users
as the argument. Should we add forum ID/topic ID as the second argument to the filters so we can check the forum/topic ID before filtering the users?
I want to make a pull request, but it seems bbpress doesn’t have public repo that accepts pull request.
Thanks!
Mauris