I made the list
<?php $args = array( 'post_type' => 'topic', 'post_parent' => bbp_get_forum_id() ); $loop = new WP_Query( $args ); ?>
<?php while ( $loop->have_posts() ) : $loop->the_post(); ?>
<a href="<?php echo get_the_permalink(); ?>"><?php the_title(); ?></a>
<?php endwhile;?>
This gives me all the topics under the current topic’s forum (I’m on single-topic.php)
Is there a way I could limit the list to 5 links (that’s easy, post_per_page = 5
) but on top of that only show the adjacent posts?
Topic 3 link
Topic 4 link
Topic 5 link <----- I'm here
Topic 6 link
Topic 7 link
In the above example, it’s showing me 2 previous adjacent posts and to next adjacent posts
What happens is if I set post_per_page
to 5 then this happens
Topic 1 link
Topic 2 link
Topic 3 link
Topic 4 link
Topic 5 link <----- I'm here
The current link is always last, I realized this is more of a wordpress question but I’d like to try my luck here since I already opened a thread
Hi,
My current WP configuration
– WordPress version: 5.4
– BBPress version : 2.6.6
– Website Link : https://kam-webagentur.fr
Problems encountered :
I installed WordPress but I am having a problem installing “bbpress” which I want to integrate with WordPress.
I arrive at the “Welcome to bbPress installer” installation interface
and this is the error message I get once I run the installation.
Fatal error: Call to undefined function: wp_check_invalid_utf8 () in /www/forum/bb-includes/functions.wp-core.php on line 60
What is the procedure to stop getting this error message ???
Thank you in advance…
I have disabled all the plugins on my site and this issue is still happening… BBpress embeds the link (to a wordpress site) The image of the landing page and intro text is displayed but the links are not clickable…
Amphibian and reptile info pages at WH
I cant upload a screenshot here but the above link shows the issue…
Any ideas?
it could be a theme or plugin issue
Themes
As a test switch to a default theme such as twentytwenty, and see if this fixes.
Plugins
If that doesn’t work, also deactivate all plugins apart from bbpress and see if this fixes. if it does, re-enable one at a time to see which is causing the error.
If you cannot do this to your site (say because it is live) then use the ‘troubleshooting’ features of this plugin to let you test without affecting other users
Health Check & Troubleshooting
Then come back
this turns comments on in bbpress
add_filter ('bbp_force_comment_status' , 'rew_set_comments_on') ;
function rew_set_comments_on () {
return true ;
}
Put this in your child theme’s function file –
ie wp-content/themes/%your-theme-name%/functions.php
where %your-theme-name% is the name of your theme
or use
Code Snippets
FYI I use the free version of GD bbPress Tools that has a setting for the User Signature. This plugin is actively updated.
GD bbPress Tools
Got the above from this stackoverflow thread
My problem is exactly like that except for bbpress
1) this is the default case – users can post topics without anyone needing to approve
2) I think this does it https://wordpress.org/plugins/wp-monalisa/ according to https://bbpress.org/forums/topic/smiley-emoticons/
3) this is what you might want https://wordpress.org/plugins/moderation-tools-for-bbpress/
Someone may need it, so I’ll update it.
function hhj_bbp_random_topic() {
global $post;
$args = array('post_type' => 'topic','orderby' => 'rand','post_status'=>'publish','posts_per_page' => '10');
$myposts = get_posts( $args );
foreach( $myposts as $post ) : setup_postdata($post); ?>
<a href="<?php the_permalink(); ?>"><?php the_title(); ?></a><br/>
<?php
endforeach;
wp_reset_postdata();
}
add_shortcode('hhj_bbp_random_topic', 'hhj_bbp_random_topic');
ref.
https://wordpress.stackexchange.com/questions/50761/when-to-use-wp-query-query-posts-and-pre-get-posts
It’s my site’s current layout, I have the forum or topic (depending on which page I’m on) on top and hopefully if I get a solution, the wordpress comments under
The plugin successfully activated once I moved to a live server, so that’s fine. But it’s not what I was looking for, am I missing something?
I’d like wordpress comments under forums or topics (single-forum.php or single-topic.php)
bbp style pack has buttons for subscribe
bbp style pack
once activated go to
dashboard>settings>bbp style pack>buttons
you can crack the code in includes/functions around line 336 if you want to look at code
probably could be this… I have access as administrator to WordPress but I dont have key master access… Will check
On the wordpress desktop, in the sidebar, where the pages, entries, settings tabs are, the forum, topics and replies tabs should show … these 3 do not appear and the forum option does not appear in the wordpress settings tab so i can’t change bbpress settings
ok, can you explain what you mean by
‘ the forum, discussion and answers tab does not appear on the wordpress desktop.’
it could be a theme or plugin issue
Themes
As a test switch to a default theme such as twentytwenty, and see if this fixes.
Plugins
If that doesn’t work, also deactivate all plugins apart from bbpress and see if this fixes. if it does, re-enable one at a time to see which is causing the error.
If you cannot do this to your site (say because it is live) then use the ‘troubleshooting’ features of this plugin to let you test without affecting other users
Health Check & Troubleshooting
Then come back
I have bbpress installed but the forum, discussion and answers tab does not appear on the wordpress desktop.
Hi,
I am trying to export a large bbpress forum to another wordpress domain using the import and export tools in the wordpress, but it is not working due to large data and server is not responding after few minutes.
Is there any other way of exporting bbpress to another domain?
Any help would be highly appreciated.
Thank you.
My env:
WooCommerce version: 4.9.0
WordPress version: 5.6
PHP version: 7.4.14
MySQL version: 5.7.31
Plugin:
bbp style pack: 4.7.2
bbPress: 2.6.6
Easy WP SMTP: 1.4.4
The feature “Notify me of follow-up replies via email” does not work on my site.
I tested: go to Settings->bbp-style-pack->Subscriptions Emails -> 9. Send test email, click on ‘Send test email(s)’, but it still does not work.
Pls guide me on this.
Hi @neon67
Thanks to reply
Did you use the “prettyphoto” plugin?
(https://wordpress.org/plugins/prettyphoto)
Best Regards,
Hyunho
I found one that works well, it puts a dropdown on the RHS to allow author override.
bbPress Topic and Reply Author Override
Private groups
and enable topic permissions
the easiest was is to create a page with the same permalink as your forum slug, so in your case ‘forums’
so create a page called ‘forums’
in the content put the html you want and follow with the shortcode [bbp-forum-index]
if you are using blocks, wordpress has a shortcode block type ‘sh’ in type and it will appear.
and publish – check that it appears as http://mysite.com/forums
and that should work
Put this in your child theme’s function file –
ie wp-content/themes/%your-theme-name%/functions.php
where %your-theme-name% is the name of your theme
or use
Code Snippets
add_action( 'bbp_theme_after_topic_author', 'rew_freshness_display_image');
function rew_freshness_display_image ($forum_id = 0) {
// Verify forum and get last active meta
$forum_id = bbp_get_forum_id( $forum_id );
$active_id = bbp_get_forum_last_active_id( $forum_id );
$link_url = $title = '';
if ( empty( $active_id ) )
$active_id = bbp_get_forum_last_reply_id( $forum_id );
if ( empty( $active_id ) )
$active_id = bbp_get_forum_last_topic_id( $forum_id );
if ( bbp_is_topic( $active_id ) ) {
//then reset forum_id to the forum of the active topic in case it is a sub forum
$forum_id = bbp_get_topic_forum_id($active_id);
$link_url = bbp_get_forum_last_topic_permalink( $forum_id );
$title = bbp_get_forum_last_topic_title( $forum_id );
} elseif ( bbp_is_reply( $active_id ) ) {
//then reset forum_id to the forum of the active topic in case it is a sub forum
$forum_id = bbp_get_reply_forum_id($active_id);
$link_url = bbp_get_forum_last_reply_url( $forum_id );
$title = bbp_get_forum_last_reply_title( $forum_id );
}
$anchor = '<a class="rew_freshness_display_image" href="' . esc_url( $link_url ) . '" title="' . esc_attr( $title ) . '"><img src="http://mysite.com/wp-content/uploads/2013/06/Brauhaus-2.jpg">' . '</a>';
echo '<p>'.$anchor.'</p>' ;
}
and change the <img src="http://mysite.com/wp-content/uploads/2013/06/Brauhaus-2.jpg" />
to the image you want – make sure it is sized right !!