BBPress inside saved BB template, or modify bbpress.php to mimic template?

How’s that for a confusing acronym-filled topic title?

I’m developing a course that uses BeaverBuilder and BBPress for the forum. I have a lovely BB template I’ve saved for course pages that I’d like to use for forum pages as well. I’ve read different threads on this forum, and it seems like there are two options:

  • use shortcodes to place the bbforums into a BeaverBuilder page that uses the template. When I do that, it makes that single page look perfect, but clicking on any links in the forum “breaks it out” of the BB page/template I’ve used and loads the page url/forums/forum/myforumname. Which, of course, is what you’d expect. So that option won’t work.

  • edit the bbpress.php template as suggested here: https://codex.bbpress.org/themes/theme-compatibility/getting-started-in-modifying-the-main-bbpress-template/ OK! I can do that. But is there an easy way to mimic my saved BB template? (“template” is confusing here-- I mean that I have created a custom page in BB and saved it as a template). I assume it’s stored in some combination of database + something else? Can you help me find the raw php so I can reuse it in bbpress.php? Or is this hopeless because the back end just doesn’t Work that Way™? If so, how do you recommend I do this?

Hey Dot,

Just letting you know that I’ve already assigned another member of the team to assist you with your concern. :slight_smile:

Thanks!

KC

Hey Dot,

BBpress generates those pages dynamically, you can’t edit them with BB. Your second option is the only way to go about it. Unfortunately, there is no easy way mimic the page layout you’ve created with BB. All data layouts are stored in the DB and there’s really no easy way to edit it. You’ll have edit the BBpress files manually to recreate your template. Sorry I don’t have a better answer for you.

Ben

I spent a little more time hunting around in the support forum, and I am wondering if this solution using the insert pages plugin would work? It seems like it’s doing the exact thing I want to do-- having the sidebar content pull from a BB page/section and put it into the template sidebar. (This way, other non-tech people could easily update the sidebar via BB, which is my goal.)

Hi Dot,

Unfortunately, I have no experience with that plugin as of yet. Therefore, if you can wait a while longer. Tomorrow, I will have a play with that plugin and see if it is possible to achieve your goal with the suggestion you mentioned.

I have added you topic to my remainder and as soon as I have more information for you, I will reply to your topic.

All the best,
Danny

Thanks, Danny! Another idea that I’m working on is using Content Aware Sidebars with a TinyMCE text editor widget on the sidebar. (The key is to have the sidebar editable by non-programmers, so if I can approximate the look and feel inside a text editor, I may be able to get away without using BB saved modules.)

In the meantime, while doing that, I ran into a problem with my sidebar template, which I just wrote up here. I think the bug may really be me not understanding how BB manages caches/pre-building under the covers, so if that’s the case, feel free to just point me in the direction of how to clear it.

I saw elsewhere in the forum that there may be some conflicts between the Insert Pages 3.0 plugin and Beaver Builder 1.6.x, so I have sufficiently solved my issue.

For anyone following along behind me, here’s what I did. I was trying to use a font icon list in the sidebar for a “quicklink” widget to link back to a site dashboard.

  • I copied tpl-sidebar.php over into bbpress.php in my child theme
  • I installed the Better Font Awesome plugin with the Black Studio TinyMCE widget. (I also installed the Content Aware Sidebars plugin to allow different customizations on different sections of the site, but that’s not strictly relevant to this issue.)
  • I recreated the font icon list functionality manually. (And that also fixed the “can’t set target in icon lists” issue handily.)

This way non-technical people can easily change the content of that widget without having to open the PHP file.

Thanks again support team for all your help!

OK, I thought I had this all figured out, but I have one more question (which again, I think may be interrelated to this question about sidebar management).

This works beautifully, for BBPress, and now I’m trying to implement it in the same way for BuddyPress. In BuddyPress, I have set up buddypress.php identically to bbpress.php and tpl-sidebar.php. Except when I view a Member page (not the directory), the sidebar doesn’t show up.

Files used (I think this is the key, probably):

  • buddypress.php for template
  • fixed-header, nav-centered, footer, and content-page.php. (The BBPress page also calls content.php, which may be why it works?). All are from the Beaver Builder parent theme.

Can you maybe help me figure out what’s going on under the covers of the template and template part pieces so I don’t have to trace through all the PHP figuring out where the sidebar is getting lost?

Hi Dot,

So I was able to use the Inset Pages plugin and add a Text Module to a bbPress page. I used Robby’s video as a guide and did pretty much the same thing.

However, I am not quite sure what you’re actually trying to achieve. As far as I can tell, you want to have a side area doesn’t necessary have to be a widget Sidebar perse. Just a side area that can be edited via the builder. Am I correct in my assumption?

If this is the case, then you should be able to use the Insert Pages plugin to achieve your goal. I think the best course of action is for you to play around with the plugin and use Robby’s video as a guide.

As for the Content Aware plugin, like the Insert Pages plugin. I have no experience. However, I will be sure to give it blast in the next few days.

All the best,
Danny

Hey, Danny-- actually your response gave me the key I needed. I think I can figure out where the problem is now. (I was looking at the system and thinking that the sidebar column wasn’t being displayed at all, but now inspecting the HTML I can see that it is being displayed but is empty.) Thanks!

Hi Dot,

No problem at all, happy to help and hear my response pointed you in the right direction. :smiley:

All the best,
Danny