• Hello everyone.

    Before posting I tried looking for solutions everywhere but apparently I cannot understand where the problem lays.
    To make a long story short, the “full width” page template doesn’t seem to work.
    I was wondering if anyone would be willing to help me understand what I could to to make this template work?
    Additional infos are that I’m using buddypress, and the page I’m interested in making full width is the forum.
    It works for other posts but not this one.
    Although it only hides the left sidebar, the post gets centered but isn’t a real “full width” anyway.

    Thanks in advance!

Viewing 9 replies - 1 through 9 (of 9 total)
  • Hi piepooh,

    I’ve had this issue before and fixed it with some CSS. Twenty Fourteen has some weird quirks, one of which forces the content, on a full page template, into a skinny little column down the middle. To fix this,

    *Very important, if you don’t already have a child theme, create one and perform your modification there.

    Add the following to your child theme’s style.css,

    .site-content .entry-header,
    .site-content .entry-content,
    .site-content .entry-summary,
    .site-content .entry-meta, .page-content {
     /* Original max-width: 474px */
     padding-top: 5px;
     max-width: 80%;
    }

    There’s also a plugin called Fourteen Extended which has an option to force content into using the full page, but if you only need the one fix, the above suggestion is a lot lighter.

    Hope this help.

    Thread Starter peipooh

    (@peipooh)

    Thank you so much @backpackersunion! It worked, although partially.

    When I click on the forum page, the sidebar is still there. However, when I go in a forum section, it gets full width, and even if it’s not completely what I wanted, I can go with that.
    However, the full width option is now not hiding the sidebar anymore, for example if you look at the picture I posted for reference in my first post, now that page does display the sidebar on the right even tho it didn’t before.

    I’m really confused, any idea of why this could be happening?

    Thanks again!

    No Problem. I’m not exactly sure what you mean with the sidebar, anyway you could paste a link? Thanks!

    Thread Starter peipooh

    (@peipooh)

    Sure! Here you can see the right sidebar even tho the template is set to full width page.

    If you check the forum, it’s the same thing, but if you actually navigate in it, it gets full width.

    Any idea why?

    Thank you so much!

    That is strange… I’m sure it comes down to the page templates, but coding is over my head.

    Best solution I could think of is using a widget plugin to control where the widgets do, or don’t show up.

    My two recommendation are,

    Dynamic Widgets – It’s can be a little tricky to understand at first, but offers by far the most versatility and customization.

    https://www.ads-software.com/plugins/display-widgets/ – Very Simple and effective. This would probably suit most peoples needs, but if you have a complicated situation, the other one would most likely cover it.

    Hope one of these does the trick!

    Thread Starter peipooh

    (@peipooh)

    Thanks for the suggestion but I can’t really seem to make the plugins work ahah!
    Oh well, I’m gonna leave it as it is for now.

    I just have one more question if by any chance you know how to fix this.
    Do you have any idea how to reduce the white space between the post body and the right sidebar? like in this page.

    I played around with the CSS a bit but it messes up everything else.

    Thanks again!

    @peipooh,

    For the issue with bbpress this is the solution that I found to be working.

    1) Copy page.php from the parent theme in to your child theme. Then remove the call to <?php get_sidebar( 'content' ); ?> and save it as bbpress.php

    2) In your child theme’s functions.php add the following function to apply the full width class to the forum pages…

    function mychildtheme_body_classes( $classes ) {
    global $content_width;
    
    if ( is_bbpress() {
        $classes[] = 'full-width';
    }
        return $classes;
    }
    add_filter( 'body_class', 'mychildtheme_body_classes' );

    If its the only function then remember to add the opening PHP <?php tag at the top of functions.php.

    Hope that helps resolve that issue.

    Regards,
    Zulf

    EDIT:

    if ( is_bbpress() {
        $classes[] = 'full-width';
    }

    should be

    if ( is_bbpress() ) {
        $classes[] = 'full-width';
    }

    EDIT once again ??

    if ( class_exists( 'bbPress' ) && is_bbpress() ) {
        $classes[] = 'full-width';
    }

    is the correct formula – thanks to @sdavis2702 for his solution here: https://www.ads-software.com/support/topic/fatal-error-call-to-undefined-function-is_bbpress-in-homepages29d396079510?replies=3#post-5470487

Viewing 9 replies - 1 through 9 (of 9 total)
  • The topic ‘Full Width Template not working with Buddypress’ is closed to new replies.