Sorted it!
/* Profile Info */
#bbpress-forums li.bbp-body div.bbp-reply-author,
#bbpress-forums li.bbp-body div.bbp-topic-author {
margin-left: 5px;
margin-top: 5px;
background: #c1c1c1;
color: #262626;
border: 1px solid black;
}
/* Header Row */
#bbpress-forums li.bbp-header .bbp-topic-author,
#bbpress-forums li.bbp-header .bbp-reply-author,
#bbpress-forums li.bbp-header .bbp-topic-content,
#bbpress-forums li.bbp-header .bbp-reply-content
#bbpress-forums div.bbp-topic-author {
color: #262626;
font-size: 16px;
}
Still, a bit clumsy using the same class name for two different things. 🙁
I have this style:
/* Profile Info */
#bbpress-forums div.bbp-reply-author, #bbpress-forums div.bbp-topic-author {
margin-left: 5px;
margin-top: 5px;
background: #c1c1c1;
color: #262626;
border: 1px solid black;
}
/* Header Row */
#bbpress-forums li.bbp-header .bbp-topic-author,
#bbpress-forums li.bbp-header .bbp-reply-author,
#bbpress-forums li.bbp-header .bbp-topic-content,
#bbpress-forums li.bbp-header .bbp-reply-content
#bbpress-forums div.bbp-topic-author {
color: #262626;
}
The problem is that the header row uses the same class name and I can’t get to one without affecting the other.
Also, it would be better if the bbp style pack plugin did not create code like this:
<span class="bsp-la-text">in </span>
The space is hard-coded. If the gap was achieved with styling then I could have added a “:” suffix which would make it even more consistent. I would be able to do that for the line:
<span class="bsp-la-text">topic by</span>
But not the “in ” line.
This is the final CSS that looks good:
/* Recent Topics Widget */
/* See also: .widget_display_topics img.avatar.photo */
.widget_display_topics ul {
background: rgba(0, 0, 0, 0.04);
padding: 10px 20px;
list-style-type: none;
margin: 0;
margin-bottom: 1.66666667em;
}
a.bsp-la-reply-topic-title {
color: #222222;
font-weight: 600;
display: block;
}
.bsp-la-text,
.bsp-la-topic-author,
.bsp-activity-freshness,
.bsp-activity-forum {
font-size:12px;
text-transform: uppercase;
}
.bsp-activity-author,
.bsp-activity-freshness,
.bsp-activity-forum {
display: inline;
}
.bsp-activity-author:after,
.bsp-activity-forum > .bsp-la-text:before {
content:"/";
margin: 0 7px;
}
.widget_display_topics ul:last-child {
margin-bottom: 0;
}
I have improved it alot:
.widget_display_topics ul {
background: rgba(0, 0, 0, 0.04);
padding: 10px 20px;
list-style-type: none;
margin: 0;
margin-bottom: 1.66666667em;
}
a.bsp-la-reply-topic-title {
color: #222222;
font-weight: 600;
}
.bsp-la-text,.bsp-la-topic-author, .bsp-activity-freshness, .bsp-activity-forum {
font-size:12px;
text-transform: uppercase;
}
.widget_display_topics ul:last-child {
margin-bottom: 0;
}
.widget_display_topics img.avatar.photo {
border: #000 solid 1px;
margin-top: -3px;
margin-right: 4px;
display:inline-block;
vertical-align:middle;
}
The only thing I would still like to do is get the final “TOPIC BY …” information to all flow as a sentence with a / delimiter. Can that be done?
There has to be something. It is very unlikely that high load is caused by PHP code only, my guess is that MySQL queries are causing high load. That too is strange, because it should not be happening normally, but at least, it can point to some configuration issue with MySQL server.
Hello, I use Elementor pro and element pack pro But the problem is going on when I can showing the forum single post then only possible to show the post by id but I can show all of the specific posts in my Elementor forum single post template I want to show all of the specific posts in this page.
Here is the shortcode for showing the single post by id [bbp-single-topic id=$topic_id]
But I can show all of the single posts without using id Is it possible can I give some solution, please
Madam @fabwintle Please give me a great solution, please
Thanks
only4kanak
I do use shortcode for bbpress index display is there another way but man is index super slow to load! latest post shortcode is fine its just the index. rest of site is fine jumping from topic to topic but something must be going on. I have researched this and seems related to shortcode or amount of posts/topics/replies? site has only 80,000 posts with 6,044 topics so not big at all
Thank you Robin for helping me,
The procedure is all clear but unfortunately the breadcrumb is still displayed above the [bbp-topic-form].
Maybe that’s because the site is also using the WOffice plugin (some code there that would pass over the content-archive-forum.php ?)
I just thought of another solution, more wobbly maybe :
I can see in the code source that this div is called <div class ="bbp-breadcrumb">
meaning that if I create a .bbp-breadcrumb
in my CSS file, I can add a display:none;
and could hide it ?
Thanks Robin for a great help. I am coding my own theme, and code from this plugin helped me to find out the filter ‘bbp_subscription_mail_message’. Though function ‘bbp_pre_notify_subscribers’ and ‘bbp_post_notify_subscribers’ are not working. But its working great with the ‘wp_mail_content_type’. It is now returning all mails from wordpress to Html emails. Anyway atleast it solved my issue. Thanks!!
Hello, I use Elementor pro and element pack pro But the problem is going on when I can showing the forum single post then only possible to show the post by id but I can show all of the specific posts in my Elementor forum single post template I want to show all of the specific posts in this page.
Here is the shortcode for showing the single post by id [bbp-single-topic id=$topic_id]
But I can show all of the single posts without using id Is it possible can I give some solution, please
Thanks
only4kanak
ok, you’ll need to edit a bbpress template using FTP
find
wp-content/plugins/bbpress/templates/default/bbpress/content-archive-forum.php
transfer this to your pc and edit
you’ll need to remove the line that says
<?php bbp_breadcrumb(); ?>
and save
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
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/content-archive-forum.php
bbPress will now use this template instead of the original
Hello,
I’m looking for the same customization as @spicynodes 8 years ago !
I have created a page with 2 shortcodes :
[bbp-topic-index]
[bbp-topic-form]
But the breadcrumb displays twice, above each one.
Is there a simple way to display it for the [bbp-topic-form] or do I necessarily need to do something in the function page (I’d prefer not too !)
Thanks for your help !
Shoutout for plugin bbPress2 shortcode whitelist.
so is this
[bbp-forum-index]
within a WordPress page ?
ok, you would be better to have a child theme to your paid theme, so maybe consider that going forward
Functions files and child themes – explained !
but what you will need to do is
find
wp-content/plugins/bbpress/templates/default/bbpress/form-user-login.php
transfer this to your pc and edit it to remove everything EXCEPT
<?php
/**
* User Login Form
*
* @package bbPress
* @subpackage Theme
*/
// Exit if accessed directly
defined( 'ABSPATH' ) || exit;
?>
and save
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
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/form-user-login.php
bbPress will now use this template instead of the original, and not show the login
If you do this in your paid theme, you will need to repeat it on every theme upgrade as that will wipe your changes out, but as long as you know that, you can place the file in your paid theme, just remember what you did ! a child theme maintains these changes.
Anonymous User 14145219Inactive
I’m using a paid wordpress theme. I can modify code if that is needed. I haven’t changed any bbPress theme thus far. Thanks for your help.
Hi Chook,
Thanks for the suggestion, but to be honest I was hoping to find out what the issue is & how to fix it as it’s only one page on the site. I’m trying to stay away from purchasing plugins for the time being as I am very early on in making the website & like to learn how it all works.
I’ve looked into this a lot however & don’t think I have the skills to find out what is wrong.
I was hoping someone might be able to understand the issue & suggest a fix.
Does anyone have any other suggestions? Robin, could the placement of short code be causing an issue as you asked in your reply?
Many thanks in advance,
Tim
After having disabled the ”bbPress Do Shortcodes” plugin I am seeing that shortcodes are now actually being interpreted in Topics without the plugin. I’m guessing that came with the recent updates to bbPress? I am seeing however that when using double brackets, which usually escapes shortcodes so that they’re not interpreted, they still seem to be partially interpreted in bbPress topics creating an error. If I use html entities instead of double brackets I am able to post a shortcode literally without it being interpreted.
Hi,
I am currently using a theme to develop my website. It provides a login page with all the validations.
I used the bbpress plugin and introduced forums on the the site. But I have the following issue with the Login and need advice.
1. I would like to use the theme login page, instead of the dfault login section that bbpress provides on the forum page.
a. Is there a way that I can remove the login section from the forum pages? By doing this the user will always be asked forced to login through the main theme login page.
b. Or can I add a Login link which redirects the user to mysite.com/login page.
I tried adding code to the function.php in the child theme to fix the redirection issue on failed login on the forum pages. But that afects the functionality of the main login page too.
So this is why I ws thinking of one of the above two solutions.
Thanks
Some functionality similar to this is planned for bbPress 2.7.
It is plausible that plugin will be used for inspiration, though the final code will likely end up being completely rewritten/modernized/debugged.
Hi Robin,
Thank you very much for replying!
Ah yes, so it’s the ‘forum index’ page that is displaying a different style to all the other pages.
I’ve used the short code: [bbp-forum-index] on the forum index page that I made in the WordPress ‘Add New’ page.
I’ve then linked the url: http://findgyms.co.uk/forums/ to the ‘Forums’ button in my header.
I hope this answers what you were asking?
In regards to the explanation in the linked item 8.. Well, that was a learning curve! I didn’t even know how to access the WordPress database but now I do!
If I’ve understand it correctly, this header issue is possible as the ‘topics’ pages in the forum posts have the correct header styling but the ‘index’ does not – from the description this says it could be due to the index page using the ‘about’ page style instead of the topics using the ‘posts’ style.
After looking in the database I think that the forum index page is using the correct ‘Astra’ theme, but not showing the correct css for my header that all my other pages are (even the ‘About’ page).
So I don’t think I would need to copy and rename the page.php file to bbpress.php (unless I wanted bbpress theme to be different to the astra theme – I think I’ve got that correct, if not apologies!)
I really appreciate any further help with this as this is becoming quite confusing for my extremely novice brain 🙂
Thanks,
Tim
hmm, I took a look, and yes it’s another theme that is lazy and does it’s css using inline, which makes it a real pain to debug or override.
but I can’t see what is wrong to cause it.
do you have a forums’s page using a shortcode or are just using a url to go to forums?
see item 8 in this to understand what I mean
Step by step guide to setting up a bbPress forum – Part 1
I would also add..
Could there be some inline code overriding my css on this page?
I don’t fully understand what I’m looking at when I right click and press ‘inspect’ on the header.. but when I unlick things in the right bottom css part it does appear to have an affect on the header styling. If so, I have no idea how to override it.
This is the css that appears to work for all my other pages:
a, .page-title {
font-family: a-love-of-thunder;
}
.ast-theme-transparent-header .site-title a, .ast-theme-transparent-header .site-title a:focus, .ast-theme-transparent-header .site-title a:hover, .ast-theme-transparent-header .site-title a:visited {
font-family: a-love-of-thunder;
}
.ast-theme-transparent-header .site-header .site-description {
font-family: a-love-of-thunder;
}
.ast-theme-transparent-header .site-title a, .ast-theme-transparent-header .site-title a:focus, .ast-theme-transparent-header .site-title a:hover, .ast-theme-transparent-header .site-title a:visited {
font-weight: normal;
text-shadow: 0px 0px 0px rgba(0,0,0,0.3);
}
.ast-theme-transparent-header .site-header .site-description {
font-weight: normal;
text-shadow: 0px 0px 0px rgba(0,0,0,0.3);
}