Search Results for '"wordpress'
-
Search Results
-
Hello,
I am running bbPress v2.5.12 on WordPress 4.7 with a child theme I’ve developed based on Imaginem Themes’ Sentric Theme.
The problem:
In my child theme’s functions, I have added the following code to make two custom roles, Professional and Member, for my Q&A/”Ask the Expert”-style forum called “Ask a Professional.” Essentially, Members can make threads asking questions, but only screened Professionals have the ability to reply and provide answers.I want everyone to automatically be assigned the Member role upon registration. Then I can manually “upgrade” their roles to Professional once they’ve been successfully screened. However, when a user registers and logs in, they inherit Member capabilities, but are not assigned the Member role. Manually selecting the user and assigning them the Member role doesn’t work; their role immediately reverts back to “— No role for these forums —”

When I select the user and manually assign the Participant role, the role “sticks” — meaning, it doesn’t revert back to “No Role.” However, the “Member” capabilities remain.

Does anyone know why this problem persists and how to fix it? This is the final thing that needs to be ironed out before my site goes live. 🙂 Thank you!
//code to add custom roles function add_new_roles( $bbp_roles ) { /* Add a role called professional */ $bbp_roles['bbp_professional'] = array( 'name' => 'Professional', 'capabilities' => custom_capabilities( 'bbp_professional' ) ); /* Add a role called member */ $bbp_roles['bbp_member'] = array( 'name' => 'Member', 'capabilities' => custom_capabilities( 'bbp_member' ) ); return $bbp_roles; } add_filter( 'bbp_get_dynamic_roles', 'add_new_roles', 1 ); function add_role_caps_filter( $caps, $role ) { /* Only filter for roles we are interested in! */ if( $role == 'bbp_professional' ) $caps = custom_capabilities( $role ); if( $role == 'bbp_member' ) $caps = custom_capabilities( $role ); return $caps; } add_filter( 'bbp_get_caps_for_role', 'add_role_caps_filter', 10, 2 ); function custom_capabilities( $role ) { switch ( $role ) { /* Capabilities for 'professional' role */ case 'bbp_professional': return array( 'spectate' => true, 'participate' => true, 'moderate' => false, 'throttle' => false, 'view_trash' => false, // Forum caps 'publish_forums' => false, 'edit_forums' => false, 'edit_others_forums' => false, 'delete_forums' => false, 'delete_others_forums' => false, 'read_private_forums' => true, 'read_hidden_forums' => true, // Topic caps 'publish_topics' => true, 'edit_topics' => true, 'edit_others_topics' => false, 'delete_topics' => true, 'delete_others_topics' => true, 'read_private_topics' => true, // Reply caps 'publish_replies' => true, 'edit_replies' => true, 'edit_others_replies' => false, 'delete_replies' => false, 'delete_others_replies' => false, 'read_private_replies' => true, // Topic tag caps 'manage_topic_tags' => true, 'edit_topic_tags' => true, 'delete_topic_tags' => true, 'assign_topic_tags' => true, ); /* Capabilities for 'member' role */ case 'bbp_member': return array( // Primary caps 'spectate' => true, 'participate' => true, 'moderate' => false, 'throttle' => false, 'view_trash' => false, // Forum caps 'publish_forums' => false, 'edit_forums' => false, 'edit_others_forums' => false, 'delete_forums' => false, 'delete_others_forums' => false, 'read_private_forums' => true, 'read_hidden_forums' => false, // Topic caps 'publish_topics' => true, 'edit_topics' => true, 'edit_others_topics' => false, 'delete_topics' => false, 'delete_others_topics' => false, 'read_private_topics' => true, // Reply caps 'publish_replies' => false, 'edit_replies' => false, 'edit_others_replies' => false, 'delete_replies' => false, 'delete_others_replies' => false, 'read_private_replies' => true, // Topic tag caps 'manage_topic_tags' => false, 'edit_topic_tags' => false, 'delete_topic_tags' => false, 'assign_topic_tags' => false, ); break; default : return $role; } }Troubleshooting:
- I’ve tried to disable plugins and see if any of them are causing this issue. This hasn’t yielded any different results.
- I’ve checked with the Twenty Sixteen and Twenty Seventeen theme.
Topic: PHP Warnings
I’m receiving a php warning when I go to http://scafra.org/
Warning: ksort() expects parameter 1 to be array, object given in /home/content/p3pnexwpnas01_data01/45/3635545/html/wp-content/plugins/bbpress/includes/core/template-functions.php on line 316When I go to /wp-login.php I receive these warnings:
Warning: ksort() expects parameter 1 to be array, object given in /home/content/p3pnexwpnas01_data01/45/3635545/html/wp-content/plugins/bbpress/includes/core/template-functions.php on line 316Warning: Cannot modify header information - headers already sent by (output started at /home/content/p3pnexwpnas01_data01/45/3635545/html/wp-content/plugins/bbpress/includes/core/template-functions.php:316) in /home/content/p3pnexwpnas01_data01/45/3635545/html/wp-login.php on line 394
Warning: Cannot modify header information - headers already sent by (output started at /home/content/p3pnexwpnas01_data01/45/3635545/html/wp-content/plugins/bbpress/includes/core/template-functions.php:316) in /home/content/p3pnexwpnas01_data01/45/3635545/html/wp-login.php on line 407
After I attempt to login, I receive an error that my password is incorrect, and then I receive these warnings:
Warning: ksort() expects parameter 1 to be array, object given in /home/content/p3pnexwpnas01_data01/45/3635545/html/wp-content/plugins/bbpress/includes/core/template-functions.php on line 316Warning: Cannot modify header information - headers already sent by (output started at /home/content/p3pnexwpnas01_data01/45/3635545/html/wp-content/plugins/bbpress/includes/core/template-functions.php:316) in /home/content/p3pnexwpnas01_data01/45/3635545/html/wp-login.php on line 394
Warning: Cannot modify header information - headers already sent by (output started at /home/content/p3pnexwpnas01_data01/45/3635545/html/wp-content/plugins/bbpress/includes/core/template-functions.php:316) in /home/content/p3pnexwpnas01_data01/45/3635545/html/wp-login.php on line 407
Warning: Cannot modify header information - headers already sent by (output started at /home/content/p3pnexwpnas01_data01/45/3635545/html/wp-content/plugins/bbpress/includes/core/template-functions.php:316) in /home/content/p3pnexwpnas01_data01/45/3635545/html/wp-includes/pluggable.php on line 893
Warning: Cannot modify header information - headers already sent by (output started at /home/content/p3pnexwpnas01_data01/45/3635545/html/wp-content/plugins/bbpress/includes/core/template-functions.php:316) in /home/content/p3pnexwpnas01_data01/45/3635545/html/wp-includes/pluggable.php on line 894
Warning: Cannot modify header information - headers already sent by (output started at /home/content/p3pnexwpnas01_data01/45/3635545/html/wp-content/plugins/bbpress/includes/core/template-functions.php:316) in /home/content/p3pnexwpnas01_data01/45/3635545/html/wp-includes/pluggable.php on line 895
Although I can’t login via WordPress, I can FTP, but I’m not sure what to change.
Topic: bbpress link error
hi.
Click on ‘forums’ and an error page will pop up.
# youtube https://youtu.be/1Ylj7TnghUA
Only WordPress installed.
I installed bbpress for the first time.# wordpress path : korear.net/
# error page : http://korear.net/wp-admin/edit.php?post_type=forumServer Specifications
– Centos 7
– Nginx: 1.10.2
– PHP7: 7.1
– Mariadb: 10.1
– WordPress 4.7I would like to remove topic author, but keep reply authors.
Please tell me how to change php files.WordPress4.7
bbPress2.5.12
Twenty Sixteen1.3(Or please summarize below.)
Is it possible to remove topic-author, but keep reply-authors
Topic: Problem with shortcodes
Am using:
Twentythirteen wordpress theme
bbPress – Version 2.5.12
With bbPress I have created a number of forums
But – when I put the following short code into a page:
[bbp-forum-index]it shows nothing …
Please – what am I doing wrong?
Dear Friends,
I’m using WP 4.7 and bbPress 2.5.12. I’m using the importer under Tools->Forums->Import forums to import a MyBB Forum (version 1.6), with 4000 topics, 50.000 messages, and 3000 users.
The performance is Ok, it takes two hours more or less. The problem, is that at certain point, the message Conversion complete is displayed, and certainly, the users / topics count is the right one. And then, without my interaction, it starts again.
I’m not sure if this “second pass” is the normal procedure, or it is an error.
Any help would be very appreciate.
That’s the output of my last attempt
Calculating forum hierarchy (0 - 999)Converting forums (0 - 999)Delete users WordPress default passwords (5000 - 5999)Delete users WordPress default passwords (4000 - 4999)Delete users WordPress default passwords (3000 - 3999)Delete users WordPress default passwords (2000 - 2999)Delete users WordPress default passwords (1000 - 1999)Delete users WordPress default passwords (0 - 999)Converting users (2000 - 2999)Converting users (1000 - 1999)Converting users (0 - 999)<strong>Conversion Complete</strong>No reply_to parents to convertConverting replies (3000 - 3999)Converting replies (2000 - 2999)Converting replies (1000 - 1999)Converting replies (0 - 999)No tags to convertNo super stickies to stickCalculating topic stickies (0 - 999)Converting topics (51000 - 51999)Converting topics (50000 - 50999)Converting topics (49000 - 49999)Converting topics (48000 - 48999)Converting topics (47000 - 47999)Converting topics (46000 - 46999)Converting topics (45000 - 45999)Converting topics (44000 - 44999)Converting topics (43000 - 43999)Converting topics (42000 - 42999)Converting topics (41000 - 41999)Converting topics (40000 - 40999)Converting topics (39000 - 39999)Converting topics (38000 - 38999)Converting topics (37000 - 37999)Converting topics (36000 - 36999)Converting topics (35000 - 35999)Converting topics (34000 - 34999)Converting topics (33000 - 33999)Converting topics (32000 - 32999)Converting topics (31000 - 31999)Converting topics (30000 - 30999)Converting topics (29000 - 29999)Converting topics (28000 - 28999)Converting topics (27000 - 27999)Converting topics (26000 - 26999)Converting topics (25000 - 25999)Converting topics (24000 - 24999)Converting topics (23000 - 23999)Converting topics (22000 - 22999)Converting topics (21000 - 21999)Converting topics (20000 - 20999)Converting topics (19000 - 19999)Converting topics (18000 - 18999)Converting topics (17000 - 17999)Converting topics (16000 - 16999)Converting topics (15000 - 15999)Converting topics (14000 - 14999)Converting topics (13000 - 13999)Converting topics (12000 - 12999)Converting topics (11000 - 11999)Converting topics (10000 - 10999)Converting topics (9000 - 9999)Converting topics (8000 - 8999)Converting topics (7000 - 7999)Converting topics (6000 - 6999)Converting topics (5000 - 5999)Converting topics (4000 - 4999)Converting topics (3000 - 3999)Converting topics (2000 - 2999)Converting topics (1000 - 1999)Converting topics (0 - 999)Calculating forum hierarchy (0 - 999)Converting forums (0 - 999)Delete users WordPress default passwords (2000 - 2999)Delete users WordPress default passwords (1000 - 1999)Delete users WordPress default passwords (0 - 999)Converting users (2000 - 2999)Converting users (1000 - 1999)Converting users (0 - 999)Starting ConversionI am having a number of issues with slow posting times. Posts are taking up to 30 seconds to submit in many cases.
I spoke to my webhost who offered the following details:
We have reviewed your case in details. As you probably know the BBPress plugin saves each forum new topic or post to a topic as a new post in the WordPress database. Due to this reason your WordPress’ posts database table and its meta data is getting quite big.
I believe that the main reason for your slow performance is the size of the _posts and _postmeta database tables.
Decreasing their size will speed your website up.
I did actually try the fix suggested at the end of this forum topic by editing the functions.php file.
This way I have managed to post a test topic for about 12 seconds instead of the previous 30-35 seconds time frame.
My forum contains 500,000+ posts, so I accept that the database will be getting large. Is there nothing that can be done to improve the awful performance I am seeing until the much rumored bbPress 2.6 is released?
Wordpress 4.7
bbPress 2.5.12Hi, I want to create different sections in my forum like on this picture

I’ve tried to make categories and then add forums to it but always the result is not like I want… Do anybody know how to do that?
It is probably very easy;)Hi,
WP 4.7, latest BBpress. I have a multisite: swissinformatic.org, magazine.swissinformatics.org, [other stuff]swissinformatics.org. My mail server is @swissinformatics.org and the plugin picks up$_SERVER['SERVER_NAME']to create the no reply address.
COULD YOU HELP US with a setting box to supersede this value?
Meanwhile I replaced it with my site name in the functions.php code, but mind the next plugin update!
$sitename = strtolower( ‘swissinformatics.org );
Always beware of “Educated guess’ I’m not going to buy a mail server for each subdomain and with the present security of providers,…
I also created a no reply alias of my administrative e-mail address.
Everything is fine nowSubscriptions ***********************************************************/
/**
* Get the “Do Not Reply” email address to use when sending subscription emails.
*
* We make some educated guesses here based on the home URL. Filters are
* available to customize this address further. In the future, we may consider
* usingadmin_emailinstead, though this is not normally publicized.
*
* We use$_SERVER['SERVER_NAME']here to mimic similar functionality in
* WordPress core. Previously, we usedget_home_url()to use already validated
* user input, but it was causing issues in some installations.
*
* @since bbPress (r5409)
*
* @see wp_mail
* @see wp_notify_postauthor
* @link https://bbpress.trac.wordpress.org/ticket/2618
*
* @return string
*/
function bbp_get_do_not_reply_address() {
$sitename = strtolower( $_SERVER[‘SERVER_NAME’] );
if ( substr( $sitename, 0, 4 ) === ‘www.’ ) {
$sitename = substr( $sitename, 4 );
}
return apply_filters( ‘bbp_get_do_not_reply_address’, ‘noreply@’ . $sitename );
