Ben Hayes (@ben-hayes)

Forum Replies Created

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

  • Ben Hayes
    Member

    @ben-hayes

    It’s a shame there doesn’t seem to be a way to get consistent breadcrumbs working across an entire site at this time with BBPress (i.e. including non-forum pages).


    Ben Hayes
    Member

    @ben-hayes

    Invalid header issues indicate you’ve installed the plugin incorrectly, or have an incomplete download.

    Hmm, OK. I downloaded the zip file from the bottom of https://bbpress.trac.wordpress.org/browser/branches/plugin and used that for the plugin, which gave me the error. Maybe Trac is not working how it should, or maybe I’ve not understood something. I’m more of a designer than a coder :) I will see if I can get my head around using Subversion to get the code instead.

    It’s possible to use the core templates, but it won’t really work the way you want it to. Why? Because when you view a single forum, you also want to view that forum’s topics. When you view a single topic, you also want to view that topic’s replies. A single flat loop isn’t enough to handle this behavior, no matter what you do.

    Right, OK. That makes sense. I hadn’t thought of that.

    I still think the whole setup is potentially quite confusing though – mainly having 2 theme locations I think is what throws me. Actually I noticed that in plugins/bbpress/bbp-themes/ it says in index.php “Do not put custom themes here or they will be overwritten”. So I know we’re not supposed to edit the theme in there. But it is still quite confusing that I can activate that theme from within the WP dashboard. This is quite unintuitive, in my view. Because we are encouraged to activate a theme that we are told we should not edit.


    Ben Hayes
    Member

    @ben-hayes

    OK I think I see what you’re saying. So WP would continue to use the page.php template to render BBP pages like forums and topics, but we can branch the logic in that page using the BBP template tags.

    Just tried this and it works.

    In case it helps anyone else, the way to remove the sidebar from BBP topic pages would be using something like this in your page.php file:

    <?php if(!bbp_is_single_topic()) { get_sidebar(); }; ?>


    Ben Hayes
    Member

    @ben-hayes

    Just realised I probably need to try the 2.1 beta version.

    I went to the URL suggested above https://bbpress.trac.wordpress.org/browser/branches/plugin and downloaded the zip file. However, WP gives me an error saying “invalid plugin header”. Anyone know how to fix this?


    Ben Hayes
    Member

    @ben-hayes

    Ah OK, I think I see that you have implemented something like this in version 2.1 :)

    I just tried to install the latest 2.1 beta version but I got an error from WP saying “Could not install this plugin as it has an invalid header” :(


    Ben Hayes
    Member

    @ben-hayes

    I followed a similar path to harnold007. Worked out that the markup of all BBP pages is being driven by page.php in my active theme directory.

    For me though, I want some pages to have a sidebar, but forum pages to be full-width.

    This seems difficult to do, because BBP is using page.php to render all its stuff.

    Have to say I admire all the work that’s clearly gone into BBP, but the way the themes are working does seem quite complex. I can’t help feeling there may be a better way of structuring it? The problem seems to be that you can *sort of* use your normal WP theme directory, but the options for controlling the layout are very limited.


    Ben Hayes
    Member

    @ben-hayes

    About that template hierarchy – my best guess was to use the same filenames as used in the sample BBP theme bbp-twentyten, but put this template in the main (active) WP theme folder. So for example, I tried making a file called single-forum.php there.

    However, that doesn’t seem to work for me – the markup still seems to be driven from page.php.

    Anyone know how to get different layouts for different pages in BBP?


    Ben Hayes
    Member

    @ben-hayes

    As far as I can see, all the BBP pages are output from the template page.php in your main WP theme. I assume there is some kind of template hierarchy we can use to override this (so we can have a specific template for ‘profile’ or ‘single topic’ etc).

    I agree it is all pretty confusing to me too ;)

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