Search Results for '+.+default+.+'
-
Search Results
-
Topic: Change user color
Hello BBPRESS community,
I really want to change color of my usergroups in my forum made by bbpress.
I have the standard role (keymaster, moderator, blocked ecc) but with names modified by editing the file functions.php in my theme folder.Now I would like to change the color in the status bar and in the topic/threads, example Administrator in the red, moderators in blue ecc.
I tried a insert this code in bbpress/templates/default/css/bbpress.css:.bbp-author-role-keymaster { background:blue; color:white; padding:0 5px; }
but it does not change anything, why?
I want to change color here
and in threads/topic discussion.
How I do?
Thank you very much.Wordpress 4.9.6
bbPress 2.5.14http://www.personalgroupware.com/wilsonlogan/
Hi All,
I have a forum in SQLITE format and I want to import it into bbPress.
I decided that if I was going to have to convert to a MYSQL database, I might as well use the schema indicated in Example.php
As I didn’t *actually* have the schema, I had to *guess* based on the fields in Example.php
For example:
CREATE TABLE IF NOT EXISTS forums_table (
_bbp_old_forum_id int(10) NOT NULL default 0,
the_parent_id int(10) NOT NULL default 0,
the_topic_count int(10) NOT NULL default 0,
the_reply_count int(10) NOT NULL default 0,
the_total_topic_count int(10) NOT NULL default 0,
the_total_reply_count int(10) NOT NULL default 0,
the_forum_title varchar(150) NOT NULL default ‘ ‘,
the_forum_slug varchar(255) NOT NULL default ‘ ‘,
the_forum_description text NOT NULL,
the_forum_order int(10) NOT NULL default 0,
the_forum_type int(10) NOT NULL default 0,
the_forum_status int(10) NOT NULL default 0
);
Having created the database as it is in Example.php, all I needed to do was load the MYSQL database from my SQLITE database.
Job done!
Yeah? Not so fast…
The import fails here:
SELECT convert(topics_table.the_topic_id USING “utf8mb4”)
AS the_topic_id,convert(topics_table.the_topic_reply_count USING “utf8mb4”)
AS the_topic_reply_count,convert(topics_table.the_total_topic_reply_count USING “utf8mb4”)
AS the_total_topic_reply_count,convert(topics_table.the_topic_parent_forum_id USING “utf8mb4”)
AS the_topic_parent_forum_id,convert(topics_table.the_topic_author_id USING “utf8mb4”)
AS the_topic_author_id,convert(topics_table.the_topic_author_ip_address USING “utf8mb4”)
AS the_topic_author_ip_address,convert(topics_table.the_topic_content USING “utf8mb4”)
AS the_topic_content,convert(topics_table.the_topic_title USING “utf8mb4”)
AS the_topic_title,convert(topics_table.the_topic_slug USING “utf8mb4”)
AS the_topic_slug,convert(topics_table.the_topic_sticky_status USING “utf8mb4”)
AS the_topic_sticky_status,convert(topics_table.the_topic_creation_date USING “utf8mb4”)
AS the_topic_creation_date,convert(topics_table.the_topic_modified_date USING “utf8mb4”)
AS the_topic_modified_date,convert(replies_table.the_topic_id USING “utf8mb4”)
AS the_topic_id FROM topics_table AS topics_table INNER JOIN replies_table
AS replies_table USING replies_table.the_topic_id = topics_table.the_topic_id WHERE forums_table.the_topic_id = 0 LIMIT 0, 100Lookee thar… a mystery field!
forums_table.the_topic_id
Are there any other mandatory fields in the import schema that are not referenced in Example.php?
And… what field from my database should I load to forums_table.the_topic_id ?
Thanks!
I am building a forum in Vietnamese language and the default title font does not display well in Vietnamese so I want to change it to Arial. How can I do it, please?
I would love to know how to hide buttons like login or register when the user is logged in and vice versa for opposite scenarios.
Im surprised that’s not how it functions by default. Why can i access the log in page when im logged in? There should be redirect options for this.
Does anyone have any suggestions that does not involve a ton of code. Remember, that’s the whole point of WP and plugins.
FYI I’m using version 4.9.6 of wordpress and version 2.5.14 of bbPress.
I added custom code to my theme functions.php page to add customized roles for bbPress. The roles show up when I edit users and want to change their roles, but when I go to save it, they just default back to a participant role. How can I fix this? Here is the code I used below:
/* bbPress Custom Roles */ function add_custom_role( $bbp_roles ) { $bbp_roles['my_custom_role2'] = array( 'name' => 'Producer', 'capabilities' => bbp_get_caps_for_role( bbp_get_participant_role() ) // the same capabilities as participants ); $bbp_roles['my_custom_role3'] = array( 'name' => 'Engineer', 'capabilities' => bbp_get_caps_for_role( bbp_get_participant_role() ) // the same capabilities as participants ); $bbp_roles['my_custom_role4'] = array( 'name' => 'Songwriter', 'capabilities' => bbp_get_caps_for_role( bbp_get_participant_role() ) // the same capabilities as participants ); $bbp_roles['my_custom_role5'] = array( 'name' => 'Staff', 'capabilities' => bbp_get_caps_for_role( bbp_get_moderator_role() ) // the same capabilities as keymaster ); $moderator = bbp_get_moderator_role() ; $bbp_roles[$moderator] = array( 'name' => 'Moderator', 'capabilities' => bbp_get_caps_for_role( bbp_get_moderator_role() ) // the same capabilities as keymaster ); $keymaster = bbp_get_keymaster_role() ; $bbp_roles[$keymaster] = array( 'name' => 'Chief Executive Officer', 'capabilities' => bbp_get_caps_for_role( bbp_get_keymaster_role() ) // the same capabilities as keymaster ); $apprentice = bbp_get_participant_role() ; $bbp_roles[$apprentice] = array( 'name' => 'Member', 'capabilities' => bbp_get_caps_for_role( bbp_get_participant_role() ) // the same capabilities as participants ); return $bbp_roles; } add_filter( 'bbp_get_dynamic_roles', 'add_custom_role', 1 );
Good Day everyone,
For a few years now I have bbPress and WordPress installed in French language.
Currently using bbpress 2.5.14 and WordPress 4.9.6.
The two language files bbpress-fr_FR.mo and bbpress-fr_FR.po are located in the wp-content/plugins/languages folder.Everything looks to work fine except that since the beginning notifications mails are sent in English language. I never figured out the reason and hope someone could help me.
Everytime it’s the default template like “Mr Foo wrote:”, “New Topic”, etc…The original WordPress install was in English language but I installed the French pack during the updates, I define (‘WPLANG’, ‘fr_FR’); in wp-config.php as well and the admin interface is in french. I don’t understand. I tried to modified the .po / .mo file with a software but no effects. I’m using WP Config SMTP plugin but I don’t think it’s related, right ?
Any help / advise would be really appreciated.
I wish to remove certain functions and text from the forum table (such as the name of the user who started the topic and his/her avatar) to reduce the cluttering. How could I delete/edit text and hyperlinks associated with bbPress?
I’m using twenty seventeen theme.
Hi guys,
I tried out bbpress recently and I am developing a multilingual website with polylang. Everything is working well and I created two forums with one for English and one for Chinese.
However, the search function for bbpress seems to only work for the default English forum even tho the user is on Chinese or English state of the website.
I tried to switch to the default templates but the issue is still there.
Does anyone have this issue and how do you solve it?
Running WordPress 4.9.6 and bbPress version 2.5.14
When someone goes to https://www.togetherpuertorico.com/forums/forum/volunteer-events-opportunities/ and enters their correct username and password and clicks on login, it takes them to the default wordpress login page rather than logging them into their bbPress account.
If they login on the default /wp-login.php page and then go back to https://www.togetherpuertorico.com/forums/forum/volunteer-events-opportunities/ it appears as though they are still not logged in, but if you click the refresh button in Chrome, it now appears that they are logged in.
I’ve tested this with both a wordpress admin user level account and a standard bbPress Subscriber, Participant user role status.
I’ve looked in the server php error log and nothing is recorded.
I’ve reverted back to the default TwentySeventeen theme to see if the theme we are using was the cause, but it still didn’t work.
Hi,
I am ploughing my way through bbp Style Pack and finding it very useful. However I have a sticking point when it comes to Buttons.
a) I can ‘activate Create Topic Button’ and ‘Activate Subscribe Button’ and the default buttons appear. (i.e. small white type on a blue background).
b) If I now attempt to enter ANY Button Style parameters (e.g. font size) then I revert back to simple text on the front-end for ‘Create New Topic’ and ‘Subscribe’.
I have tried including specific values for all the Button Style parameters but still I just get text on the front-end.Geoff
Topic: Widgets
Hi, I’d like to make a custom widget with the default bbpress forum list widget as a code starting point. Where would I locate these, and where should I place them once I make it? Should i turn it into a personal plugin so i can use it on other sites if I wish?
It’s just that the default one is meant for a side bar, and I want one for under my header on my main page.
Hello there!
Ever since starting to work with bbPress (and Learnpress), all new users were assigned the site roles ‘subscriber, and participant’ and the forum role ‘instructor’.
I don’t want all forum users to have the role ‘instructor’, since they aren’t. I have checked, but my default is really set to participant.
See screenshots:
https://drive.google.com/open?id=1RlJVw0QHIVV3Hp-MWvOdtYjh5cKAM6MR
https://drive.google.com/open?id=1EAzfa2gQLyv20hmCVHGW65ueb8KBNUyV
How can I make sure people will be assigned a normal forum role instead?
My current versions (but I have had this issue for about 1,5 years now):
WordPress 4.9.6
BbPress Version 2.5.14
BuddyPress Version 3.0.0
LearnPress Version 3.0.8
LearnPress BbPress integration Version 3.0.1
LearnPress BuddyPress integration Version 3.0.2My website: http://www.InevitableBliss.com
The forum: https://inevitablebliss.com/community/Topic: Change bbpress post type?
I would like to change my default post type from standard to video.
Is there any way to do this?
Hi!
I am trying to make any topics and replies submitted on the front end have a default category (I have extended the custom post type of bbPress to support categories). This works for everything submitted on the back end, but not everything submitted on the front end. I have played around with this a lot, and have not made any progress.
I am using WordPress 4.9.5, bbPress 2.5.14 and the site I am working on (locked so this link probably won’t do any good) is https://gateway.aishasalem.com
// adding possibilities to have categories for custom post types public function gt_custom_post_type_categories() { register_taxonomy_for_object_type( 'category', 'topic' ); register_taxonomy_for_object_type( 'category', 'reply' ); } add_action( 'init', 'gt_custom_post_type_categories', 11 );
And this code to assign the categories as default when a post is saved / published. It works on the back end, but only partially on the front end.
// setting default post catagory when saving public function gt_set_default_category( $post_id, $post, $update ) { // Slugs of the custom post types $slugs = array('topic', 'reply'); // current post type $current_post_type = $post->post_type; // If this post isn't a custom posty type, don't update if ( !in_array($current_post_type, $slugs) ) { return; } // Sets the default category depending on the current post type switch ($current_post_type) { case 'topic': $default_category = 'livingroom-topics'; break; case 'reply': $default_category = 'livingroom-replies'; // does not hook in on the fron end break; default: return; } // sets the default category $default_term = get_term_by('slug', $default_category, 'category'); wp_set_object_terms(get_the_ID(), $default_term->term_id, 'category'); } add_action( 'save_post', 'gt_set_default_category', 9, 3 );
I have tried hooking into ‘bbp_new_reply’ but this doesn’t seem to help (maybe I am doing it wrong). Do you have any advice of how to do this? Where to hook into? If it should be a filter and a function of a different form (if so, please give as much info as possible, I am new to php wordpress and especially filters)?
Thank you so much!!
Topic: User Role Modification
Hello,
I have a bbPress site. I want to change some role permission.
1. Participant Role will be able to delete their post and topic.
2. Annonymous user can delete their post and reply.
For number 1. I tried to follow this post but i am very confused. I added this code to theme childfunction.php
add_filter ('bbp_get_topic_trash_link', 'topic_dont_delete'); add_filter ('bbp_get_reply_trash_link', 'reply_dont_delete'); function topic_dont_delete( $args = '') { // Parse arguments against default values $r = bbp_parse_args( $args, array( 'id' => 0, 'link_before' => '', 'link_after' => '', 'sep' => ' | ', 'trash_text' => esc_html__( 'Trash', 'bbpress' ), 'restore_text' => esc_html__( 'Restore', 'bbpress' ), 'delete_text' => esc_html__( 'Delete', 'bbpress' ) ), 'get_topic_trash_link' ); $actions = array(); $topic = bbp_get_topic( bbp_get_topic_id( (int) $r['id'] ) ); if ( empty( $topic ) || !current_user_can( 'delete_topic', $topic->ID ) ) { return; } if ( bbp_is_topic_trash( $topic->ID ) ) { $actions['untrash'] = '<a title="' . esc_attr__( 'Restore this item from the Trash', 'bbpress' ) . '" href="' . esc_url( wp_nonce_url( add_query_arg( array( 'action' => 'bbp_toggle_topic_trash', 'sub_action' => 'untrash', 'topic_id' => $topic->ID ) ), 'untrash-' . $topic->post_type . '_' . $topic->ID ) ) . '" class="bbp-topic-restore-link">' . $r['restore_text'] . '</a>'; } elseif ( EMPTY_TRASH_DAYS ) { $actions['trash'] = '<a title="' . esc_attr__( 'Move this item to the Trash', 'bbpress' ) . '" href="' . esc_url( wp_nonce_url( add_query_arg( array( 'action' => 'bbp_toggle_topic_trash', 'sub_action' => 'trash', 'topic_id' => $topic->ID ) ), 'trash-' . $topic->post_type . '_' . $topic->ID ) ) . '" class="bbp-topic-trash-link">' . $r['trash_text'] . '</a>'; } if ( bbp_is_topic_trash( $topic->ID ) || !EMPTY_TRASH_DAYS ) { if ( bbp_is_user_keymaster()) { $actions['delete'] = '<a title="' . esc_attr__( 'Delete this item permanently', 'bbpress' ) . '" href="' . esc_url( wp_nonce_url( add_query_arg( array( 'action' => 'bbp_toggle_topic_trash', 'sub_action' => 'delete', 'topic_id' => $topic->ID ) ), 'delete-' . $topic->post_type . '_' . $topic->ID ) ) . '" onclick="return confirm(\'' . esc_js( __( 'Are you sure you want to delete that permanently?', 'bbpress' ) ) . '\' );" class="bbp-topic-delete-link">' . $r['delete_text'] . '</a>'; } } // Process the admin links $retval = $r['link_before'] . implode( $r['sep'], $actions ) . $r['link_after']; return $retval ; } function reply_dont_delete( $args = '' ) { // Parse arguments against default values $r = bbp_parse_args( $args, array( 'id' => 0, 'link_before' => '', 'link_after' => '', 'sep' => ' | ', 'trash_text' => esc_html__( 'Trash', 'bbpress' ), 'restore_text' => esc_html__( 'Restore', 'bbpress' ), 'delete_text' => esc_html__( 'Delete', 'bbpress' ) ), 'get_reply_trash_link' ); $actions = array(); $reply = bbp_get_reply( bbp_get_reply_id( (int) $r['id'] ) ); if ( empty( $reply ) || !current_user_can( 'delete_reply', $reply->ID ) ) { return; } if ( bbp_is_reply_trash( $reply->ID ) ) { $actions['untrash'] = '<a title="' . esc_attr__( 'Restore this item from the Trash', 'bbpress' ) . '" href="' . esc_url( wp_nonce_url( add_query_arg( array( 'action' => 'bbp_toggle_reply_trash', 'sub_action' => 'untrash', 'reply_id' => $reply->ID ) ), 'untrash-' . $reply->post_type . '_' . $reply->ID ) ) . '" class="bbp-reply-restore-link">' . $r['restore_text'] . '</a>'; } elseif ( EMPTY_TRASH_DAYS ) { $actions['trash'] = '<a title="' . esc_attr__( 'Move this item to the Trash', 'bbpress' ) . '" href="' . esc_url( wp_nonce_url( add_query_arg( array( 'action' => 'bbp_toggle_reply_trash', 'sub_action' => 'trash', 'reply_id' => $reply->ID ) ), 'trash-' . $reply->post_type . '_' . $reply->ID ) ) . '" class="bbp-reply-trash-link">' . $r['trash_text'] . '</a>'; } if ( bbp_is_reply_trash( $reply->ID ) || !EMPTY_TRASH_DAYS ) { if ( bbp_is_user_keymaster()) { $actions['delete'] = '<a title="' . esc_attr__( 'Delete this item permanently', 'bbpress' ) . '" href="' . esc_url( wp_nonce_url( add_query_arg( array( 'action' => 'bbp_toggle_reply_trash', 'sub_action' => 'delete', 'reply_id' => $reply->ID ) ), 'delete-' . $reply->post_type . '_' . $reply->ID ) ) . '" onclick="return confirm(\'' . esc_js( __( 'Are you sure you want to delete that permanently?', 'bbpress' ) ) . '\' );" class="bbp-reply-delete-link">' . $r['delete_text'] . '</a>'; } } // Process the admin links $retval = $r['link_before'] . implode( $r['sep'], $actions ) . $r['link_after']; return $retval ; }
But as I understood that, it was trashing post not deleting them. What I have missed? This code didnot worked for me. May be I have missed some steps.
And for 2, I don’t know if its possible or not. Searched a lot but haven’t found any solution yet. My understanding is annonymous is not a role, nore a user. So how we can achieve that?
Thank You