Skip to:
Content
Pages
Categories
Search
Top
Bottom

Calling get_sidebar not working on forum and topic pages


  • jeffvand
    Participant

    @jeffvand

    I have created a page template to call a custom sidebar for bbpress. It works great on the archive-forum.php page, but when I put the same code on the single-forum.php or single-topic.php page I am getting a “Oh bother! No forums were found here!” message where the sidebar should be.

    My sidebar is called sidebar-bbpressside.php. I am calling it with the following code:

    get_sidebar('bbpressside'); 
    

    Any thoughts how I can get that working on the sub-pages too? Weird.

    Thanks!

    • This topic was modified 2 years, 2 months ago by  jeffvand.
    • This topic was modified 2 years, 2 months ago by  jeffvand.
    • This topic was modified 2 years, 2 months ago by  jeffvand.
Viewing 2 replies - 1 through 2 (of 2 total)

  • jeffvand
    Participant

    @jeffvand

    Any update on this one? What I think I really want to do is create a sidebar like the one on these forums where there is a Forum Info, a Topic Info, a Topic Tags, and a Search field.

    Any tips on how I can make that happen? :) That would be fantastic!


    John James Jacoby
    Keymaster

    @johnjamesjacoby

    Sounds like something in your sidebar is calling query_posts() or some other query that’s nooping your main query loop. Or, your sidebar is being included before the main content, and manipulating the main query.

    Either way, you’ll probably have better luck making a bbpress.php template in the root of your theme, and including your sidebar there. That way it’s done in one shot, without needing to manipulate a bunch of template files.

Viewing 2 replies - 1 through 2 (of 2 total)

You must be logged in to reply to this topic.