Forum Replies Created
-
In reply to: Shortcodes in Sidebar
suspect that as bbpress has custom post types, your sidebar manager is responsible
so standard testing advice is
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
Then come back
In reply to: Shortcodes in Sidebarmay well be theme/plugin related, can you give a specific example please
untested, but this should take out newlines and change the excerpt length to 150 – just change the 150 in the code to whatever length you want.
so firstly you need to alter the default in wordpress which is 55 so
add_filter( 'excerpt_length', 'rew_change_default_length' ) ; function rew_change_default_length () { return 150; }then alter it in the bbpress function, and change to take out line breaks
add_filter ('bbp_get_topic_excerpt' , 'rew_remove_line_breaks', 10 , 3) ; function rew_remove_line_breaks ($excerpt, $topic_id, $length){ $topic_id = bbp_get_topic_id( $topic_id ); //change length here $length = 150 ; $excerpt = get_post_field( 'post_excerpt', $topic_id ); if ( empty( $excerpt ) ) { $excerpt = bbp_get_topic_content( $topic_id ); } $excerpt = trim( strip_tags( $excerpt ) ); //take out line breaks $excerpt = preg_replace("/\r|\n/", "", $excerpt); // Multibyte support if ( function_exists( 'mb_strlen' ) ) { $excerpt_length = mb_strlen( $excerpt ); } else { $excerpt_length = strlen( $excerpt ); } if ( ! empty( $length ) && ( $excerpt_length > $length ) ) { $excerpt = mb_substr( $excerpt, 0, $length - 1 ); $excerpt .= '…'; } // Filter & return return apply_filters( 'rew_get_topic_excerpt', $excerpt, $topic_id, $length ); }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
In reply to: Remove Category Hyperlink?@joel-mohanraj
find
wp-content/plugins/bbpress/templates/default/bbpress/loop-single-forum.phptransfer this to your pc and edit
so you will want to take the link out of line 34
<a class="bbp-forum-title" href="<?php bbp_forum_permalink(); ?>"><?php bbp_forum_title(); ?></a>and save
create a directory on your theme called ‘bbpress’
ie wp-content/themes/%your-theme-name%/bbpresswhere %your-theme-name% is the name of your theme
Then transfer the file you saved above and put in in the directory called bbpress that you created above, so you end up with
wp-content/themes/%your-theme-name%/bbpress/loop-single-forum.phpbbPress will now use this template instead of the original
amending the freshness will require you to amend the
bbp_get_forum_freshness_linkfunction. if you are familiar with filters you can use the filter on line 585 of \includes\forums and a str_replace to take out the linkIn reply to: Remove Category Hyperlink?sorry, not sure which exact part you want to replace.
so is this the links in the forum list of topics? or everywhere or what?
In reply to: Subscribe to all forums buttonif that works, go for it 🙂
In reply to: how to limit the number of usersIn reply to: Thumbs up and downsorry, best I can suggest
In reply to: Subforum Function Stopped Workinggreat – glad to have been a small help
In reply to: how to limit the number of usersuh?
please rephrase as to what you want?
In reply to: Non-email based notifications of replies?sorry, best I can suggest
In reply to: Thumbs up and downsorry, this one
In reply to: Subforum Function Stopped Workingps – I presume you have a function
groups_join_groupbut have not shown it for simplicity ?In reply to: Subforum Function Stopped Workingjust looked at this – sorry, as you say I don’t get to every item, and this is bespoke code which means something to someone, but without a heavy investment of time, it is hard to debug why it is not working 🙂
the function bbp_add_user_forum_subscription is still valid, and should work fine, so the actual change to the way bbpress works should not affect it.
I have little knowledge of buddypress, so I cannot say whether that code is still valid.
Have you turned debugging on ? and is it showing anything ?
In reply to: Non-email based notifications of replies?there is the ‘unread posts’ part of my style pack plugin, that will advise users on the website of new unread topics, and new unread replies to topics.
once activated go to
dashboard>settings>bbp style pack>Unread Posts
In reply to: Double click on send button make duplicate postyou’re welcome 🙂
In reply to: Forum category not shownlink to a live example please
In reply to: Thumbs up and downthis add-on plugin to bbpress does that. Whilst old, it still works
In reply to: Double click on send button make duplicate postJust had a thought and dug in the code further, the duplicate check doesn’t apply to those roles/users that can ‘throttle’
// No duplicate checks for those who can throttle if ( user_can( (int) $r['post_author'], 'throttle' ) ) { return true; }so default Keymaster and Moderator can post duplicates
In reply to: Real age verification access control?most 10 year olds can fake a photo ID – there is no real way to verify someone on line 🙂
But if you find or create a mechanism, in the spirit of open software, do come back and let us know
In reply to: Double click on send button make duplicate postI am not a bbpress author, just someone who helps out here.
Every website is unique, and this doesn’t happen on my test site – I have not seen this reported elsewhere as an issue, and the code has a duplicate function check in it.
line 307 of includes/replies/functions
/** Reply Duplicate *******************************************************/ if ( ! bbp_check_for_duplicate( array( 'post_type' => bbp_get_reply_post_type(), 'post_author' => $reply_author, 'post_content' => $reply_content, 'post_parent' => $topic_id, 'anonymous_data' => $anonymous_data ) ) ) { bbp_add_error( 'bbp_reply_duplicate', __( '<strong>Error</strong>: Duplicate reply detected; it looks as though you’ve already said that.', 'bbpress' ) ); }I am not able to say why you are getting this.
In reply to: Real age verification access control?bbpress just uses wordpress registration and login, so you can use any wordpress plugin that would do that.
I googled and got this list
In reply to: Real age verification access control?nothing I know of
In reply to: can I make the UI cleaner for creating topics?you can switch to a text editor, which looks way better
once activated go to
Styling
dashboard>settings>bbp style pack>Topic/Reply Formitem 9
In reply to: can I make the UI cleaner for creating topics?this is the ‘tiny mce’ editor that comes bundled with WordPress which bbpress just uses.
from a quick google it doesn’t look that easy to change what is there.