Skip to:
Content
Pages
Categories
Search
Top
Bottom

Search Results for 'remove sidebar'

Viewing 25 results - 1 through 25 (of 297 total)
  • Author
    Search Results
  • #188123
    leeproc
    Participant

    Hello all,

    I somehow broke the page layout of my topic index and topic pages. The sidebar should be on the right, but it looks like WordPress is drawing the gray line separator on the left of the page, and pushing all the sidebar content to the bottom. Example: https://www.parentifact.org/forums/forum/questions/

    I thought this was due to some code I put in the style.css and functions.php to style my archive pages, but I removed that code and it’s still messed up. Has anyone experienced this before, or could someone more knowledgeable look at the source and developer tools to figure out what’s going wrong here?

    Thanks!

    #187404

    Topic: Remove sidebar?

    in forum Plugins
    loiruca
    Participant

    HI, I found many articles on how to remove the sidebar from bbpress pages but nothing I do works for me. I’ve already checked my theme and sidebar is enabled. I’ve tried commenting out the <?php get_sidebar(); ?> under all bbpress templates files. I’ve tried hiding it with CSS.

    The index forum pages and topics don’t show sidebar, but when I go to other pages like a user account or a tag, etc then the sidebar is there. Please, anyone, help me. I’m not sure what to do anymore.

    pmatteudi
    Participant

    Hi there,

    I’m writing because I have trouble to understand how templates are managed in BBPress (and wordpress I guess :)).
    I’d like to have a specific template on the main forum page (the one displaying the different forums). And another template for the page displaying the different topics.

    Currently in the wordpress page where I pasted the short code [bbp-forum-index], I call the template bbpress.php, which is presented in the bbpress codex (See example at the end of the topic).

    But how can I create a specific template for my forum index (listing all my forums), for instance “forum-display.php”. And another template, listing my topics (for instance “topic-display.php”).

    Maybe my file bbpress.php is not appropriate to do so ? or need to be customized a bit ?

    NB : I’m using twenty twelve theme

    I hope my question is clear,
    Thank you for your help,
    Pierre

    <?php
     
    /*
    Template Name: index-forum
    */
     
    get_header(); ?>
      
    <div id="primary" class="site-content">
     
    		<div id="content-forum" role="main">
    	 
    	 
    		<?php
    		/*
    		Start the Loop
    		*/
    		
    		while ( have_posts() ) : the_post(); ?>
    		 
    		 
    		<?php
    		/*
    		This is the start of the page and also the insertion of the post classes.
    		 
    		Post classes are very handy to style your forums.
    		*/
    		?>
    		 
    			<article id="post-<?php the_ID(); ?>" <?php post_class(); ?>>
    			<?php
    			/*
    			This is the title wrapped in a header tag
    			and a class to better style the title for your theme
    			*/
    			?>
    		 
    			<header class="entry-header">
    			 
    			<h1 class="entry-title"><?php the_title(); ?></h1>
    			 
    			</header>
    			 
    			 
    			<?php
    			/*
    			This is the content wrapped in a div
    			and class to better style the content
    			*/
    			?>
    		 
    			<div class="entry-content">
    			<?php the_content(); ?>
    			</div>
    			 
    			<!-- .entry-content -->
    			 	 
    			</article>
    			 
    			<!-- #post -->
    			<?php endwhile; // end of the loop. ?>
    		 
    		</div>
    	 	<!-- #content -->
    	 	
    	 	<div class="login-sidebar"><?php dynamic_sidebar('forum_login_zone');?></div>
    
    </div> 
    	<!-- #primary -->
      
    <?php
    /*
    This is code to display the sidebar and the footer.
    Remove the sidebar code to get full-width forums.
    This would also need CSS to make it actually full width.
    */
    ?>
    		 
    <?php get_footer(); ?>
    #186733
    fdarn
    Participant

    Hello.
    I am using the latest version of bbPress on WordPress 4.8.1
    How do I remove the sidebar from the Forum pages?
    Thank you
    screenshot

    #185707
    Howdy_McGee
    Participant

    Ok, here’s what I did. If anyone has a better solution post it! What I was ultimately trying to do was combine both the WooCommerce accounts sidebar with the BBPress sidebar. I think the most difficult part / part I’m most unsure about is the bbp user ID which we’ll get to later.

    Unloading a Template

    I used the bbp_get_template_part filter to find and remove the user-details.php template from loading:

    /**
     * Prevent BBPress from loading certain templates
     *
     * @param Array $templates
     *
     * @return Array $templates;
     */
    function prefix_bbp_template_removal( $templates ) {
    
    	if( bbp_is_single_user() && is_array( $templates ) ) {
    		
    		
    		if( false !== ( $key = array_search( 'user-details.php', $templates ) ) ) {
    			unset( $templates[ $key ] );
    		}
    		
    	}
    	
    	return $templates;
    	
    }
    add_filter( 'bbp_get_template_part', 'prefix_bbp_template_removal');

    Loading a Template

    Then I used the bbp_locate_template() function to reload the template where I wanted it.

    bbp_locate_template( array( 'user-details.php' ), true, false );

    User Profile Links

    This is where it gets hairy. For whatever reason, when outside the “User Home”, BBPress doesn’t know which user is displaying so none of the sidebar links would link plus “Edit” and “Subscriptions” were missing. To show the last 2 links I needed to have bbp_is_user_home return true, in my case it was whenever the user was on WooCommerce Accounts pages:

    /**
     * Modify Home Conditional if viewing WooCommerce Account
     *
     * @return Boolean
     */
    function prefix_bbp_user_home( $is_user_home ) {
    	
    	if( function_exists( 'is_account_page' ) && is_account_page() ) {
    		$is_user_home = true;
    	}
    	
    	return $is_user_home;
    	
    }
    add_filter( 'bbp_is_user_home', 'prefix_bbp_user_home' );

    Which now shows the two links at the bottom. The final piece was actually getting the links to work correctly. This is what I’m most unsure about as I’m not sure how BBPress defines which user is displayed. I’m assuming there’s some kind of impersonation feature which makes this more difficult or something I’m not sure so I just return the current user ID:

    /** 
     * Give BBPress a User ID on Woocommerce Accounts
     *
     * @param Integer $bbp_user_id
     *
     * @return Integer $bbp_user_id
     */
    function prefix_bbp_user_id( $bbp_user_id ) {
    	
    	$user_id = get_current_user_id();
    	
    	if( function_exists( 'is_account_page' ) && is_account_page() && empty( $bbp_user_id ) ) {
    		$bbp_user_id = $user_id;
    	}
    	
    	return $bbp_user_id;
    		
    }
    add_filter( 'bbp_get_user_id', 'prefix_bbp_user_id' );

    I’d love to get some clarification on the BBPress user ID, why it doesn’t use the current user outside User Home, and what the best way to go about this is.

    #185355
    Droidism
    Participant

    WordPress version 4.8
    bbPress version 2.5.12
    Site URI: Localhost (I can create a temp vpn tunnel to the site if needed.)

    Hi,

    I am confused about the following setup and theme page template/bbPress weirdness.

    I have installed bbPress and set the forum root to “support” and saved changes.
    Then I created a page with the exact same name “support“. The slug matches the page name and reads: www.mysite/support/
    In this page I have added the bbpress short code [bbp-forum-index]

    With the current theme I have the option to choose a page template with or without a sidebar. When I set the page template to “sidebar“, the sidebar does NOT display.

    When I change the “forum root” from “support” to “forums” and leave the page name and template choice as is, the sidebar does display.

    The same applies when I do not change the Forum root and leave it as “support“, but I remove the bbPress shortcode [bbp-forum-index]. The page “support” does show the sidebar.

    I am wondering if I am doing something wrong with either setting the Forum root slug and the page name to the exact same; “support“.

    Maybe this is not possible and leads to url/permalink confusion in WP/bbPress and it instead uses the “standard” page template (which doesn’t utilises any sidebars in the current theme I am using.)

    In the end what I would like to see is the following (if possible at all.);

    When you visit the site’s support page the url/slug read: www.mysite.com/support/
    The page title matches the slug: “Support” and it uses the sidebar page template.

    In this page the support questions are shown by freshness and the breadcrumb actually displays “home >> support“, not “home >> forums“.

    Thanks in advance for any help in explaining the Forum root and page name scheme/setup.

    #185330
    ScottyChoc
    Participant

    WordPress version 4.8
    Genesis Theme version 2.5.2
    bbPress version: 2.5.12
    Site URL: http://staging.c-rad.org/

    My site has a members section for which all of the pages in it have a template applied to it with this simple logic:

    	if ( ! is_user_logged_in()) {
    		wp_login_form();
    		return;
    	} else {
    		// add the members only sidebar and show the content
    	}
    

    Is it possible to install bbPress such that I can apply this template logic to all forum pages?

    I also want all forum pages to exist under a parent page. e.g. c-rad.org/members/forums.

    I can place my forum there (c-rad.org/members/my-forum) using a shortcode, but then all other forum pages go to their default locations (c-rad.org/topic/my-topic).

    I tried changing the Forum Root to ‘members’, but then when I visit that page, the page template with my logic is removed.

    locutus1
    Participant

    I first heard of WordPress only recently. Today, I heard about CSS for the first time. This must give people the ability to customize anything on their site.

    1) I have a page that I set to be the Front page. So in the menu bar I can click Home or I can click the title of the page to load the page. Having Home in the menu bar makes sense but that means I don’t need the title of the page to be there too. How do I remove the page title so the only way to load the page is by clicking Home?

    2) I have a link to a privacy policy in the menu bar. I heard one can put page links in the site’s footer. That makes sense. I want to do that. I found these instructions:
    Create a new menu, “Footer Menu” for example
    Add-in whatever links (pages) are needed there
    Add a widget (called Custom Menu) to a footer widget position (if your current theme supports it)

    I went to Customize and made a menu called Footer. I went to Appearance…Menu and added Privacy Policy to the Footer menu. I went to Appearance…Widgets and found Custom Menu. That’s as far as I got. How do I add custom menu to the “footer widget position”? Maybe my theme doesn’t support it. If I click Custom Menu, I see only “Right Sidebar” and “Add Widget”. If I go to my site, at the bottom I see “2017… Developed by Tamal Anwar”. Is that area at the bottom the footer?

    Thanks.

    #182111
    phil49
    Participant

    Hi Robin !

    LOL !

    I talk too much, but as I want to give as many detail as possible…

    Your code is working for the pages of the site.

    Your code is NOT working for ALL the forum pages of the site

    Your code is applied for all the pages, that’s it takes almost 100% of the page, but site pages are not concerned by my problem.

    Your code doesn’t make any difference when applied to the forum pages.

    I was just adding in my previous post that I have the same problem for my second issue with the background gradient that is not applied either, unless the code is not correct, but I don’t think so !

    Thinking about all this yesterday, I’ve got the feeling that in fact, what is desperately keeping void corresponds to the place that should be occupied by the sidebar, even though I told you that I have no sidebar on all the site pages as well as the forum pages.
    But there’s a section dedicated to its management in this new theme and version of WordPress 4.7.2 !
    I removed all the widgets initially present in this sidebar but maybe the code keeps holding the place !?

    It’s as if this part of the code keeps applying in the end, prevailing on the child theme css code !

    Hope this is clear now ! 😉

    Regards,

    Philippe

    #181112
    stewmills
    Participant

    Thank you kindly, Pascal!

    The links I would like removed are listed in two separate posts as follows. Note that I have edited the actual link data in my note below so I don’t create yet another link here, but you can easily identify the links in my posts per the information I am providing below:

    topic link 1: https://bbpress.org/forums/topic/hide-home-menu-on-bbpress-pages/
    Link to remove 1: http://www.cyt*****.com/user*****/

    topic link 2: https://bbpress.org/forums/topic/bbpress-sidebar-disappears-on-topicpost-pages/
    Link to remove 2.1: http://www.cyt*****.com/for**/
    Link to remove 2.2: http://www.cyt*****.com/for***/forum/regist******-instru******-and-fo***-guide*****/

    Thank you!

    #181214
    stewmills
    Participant

    To the best of my memory, I added the below to my themes’s child functions.php file to disable the “forums” breadcrumb that links back to the “forums” page that does not include the sidebar. NOTE that I am not a developer and got the below from this forum somewhere last year so use at your discretion. If you crash your site, I accept no responsibility!!
    +++++++++++++++++++++++++++++++++++++++++

    function rkk_custom_bbpbreadcrumbs() {
    // Remove Forum root from bbPress breadcrumbs
    $args[‘include_root’] = false;
    return $args;
    }

    add_filter(‘bbp_before_get_breadcrumb_parse_args’, ‘rkk_custom_bbpbreadcrumbs’);

    #180815

    In reply to: Font-Size

    figoo
    Participant

    The code you wrote didn’t work, but your plugin does. Almost exzellent 😀

    I have a different question, and I know many post becouse of this issue exist.
    But none of them got me to a resolution.

    How can I use the full width for my forums? At the homepage of my forumsite it works nice, but as soon as I click on a Forum the disgusting sidebar comes from the right. I tried copying the page.php an rename it to bbPress.php and remove all things that have to do with sidebars. That didn’t work.

    Here is the code:

    <?php
    /**
     * The template for displaying all pages.
     *
     * This is the template that displays all pages by default.
     * Please note that this is the WordPress construct of pages
     * and that other 'pages' on your WordPress site will use a
     * different template.
     *
     * @package Sydney
     */
    
    get_header(); ?>
    
    			<?php while ( have_posts() ) : the_post(); ?>
    
    				<?php get_template_part( 'content', 'page' ); ?>
    
    				<?php
    					// If comments are open or we have at least one comment, load up the comment template
    					if ( comments_open() || get_comments_number() ) :
    						comments_template();
    					endif;
    				?>
    
    			<?php endwhile; // end of the loop. ?>
    
    		</main><!-- #main -->
    	</div><!-- #primary -->
    
    <?php get_footer(); ?>
    #179971
    mikel1980pamplona
    Participant

    Hello everyone.

    I have a question with sigle-topic.php.

    If I want to put the topics as full width (while the rest of the forum has sidebar) I remove the call to the sidebar, but it all concerns me.

    What and where do I put it to be full width?

    #179944
    mikel1980pamplona
    Participant

    Hello everyone!

    I want to do one thing on my bbpress and I’d like to do it without plugins.
    Currently my entire forum is full width. In my child theme I included the template “fullwidth-page.php” renaming it as “bbpress.php”.
    It worked perfect.
    My intention now is to see the sidebar in the whole forum, but in the pages of topics is full width.
    I think it improves the user experience. When they see the main page of forum, with the listings of forums, or when they enter a specific forum does not bother the sidebar to see what topics exist. But I would like to remove the sidebar when the user enters a topic or will do anything in it (read it, respond, etc …)

    Do you know how I can do this?

    If I delete the template I made to remove the sidebar (“fullwidth-page.php” renamed as “bbpress.php”) I get the sidebar in the forum.
    But what do I do next to remove the topics sidebar and everything related to them?

    Thanks greetings!

    #179660
    Arutam
    Participant

    HI,

    I used to have this code in my forum to make it full-width.

    /* Hide SideBar in bbPress Profiles and Topics*/
    function disable_all_widgets( $sidebars_widgets ) {       
        if ( function_exists('is_bbpress') ) {
            if (is_bbpress()) {
                $sidebars_widgets = array(false);
                remove_all_actions('bp_register_widgets');
                unregister_sidebar( 'bp_core_widgets' );
            }
        }
        return $sidebars_widgets;
    }
    
    add_filter('sidebars_widgets', 'disable_all_widgets', 1, 1);

    Is there a way to apply full-width only for Forums and Topics (opened)?

    Thanks,

    #179458
    xmatter
    Participant

    Today I changed theme to GeneratePress. Under the “Forums” Page, I changed Content No Sidebar & Full Width Content. Still the Forums page will NOT remove the sidebar. When originally installing bbPress, I created a Forums page with the slug “forums” and that is how its communicating. From there as a diagnostic step, I created another page named Forums2 and added the shortcode to display the forums index. That page would NOT displat it full width (no sidebar) no matter what I tried. Any help would be awesome.

    #179446
    Arutam
    Participant

    Try this code. Put it on the function.php

    /* Hide SideBar in bbPress Profiles and Topics*/
    function disable_all_widgets( $sidebars_widgets ) {       
        if ( function_exists('is_bbpress') ) {
            if (is_bbpress()) {
                $sidebars_widgets = array(false);
                remove_all_actions('bp_register_widgets');
                unregister_sidebar( 'bp_core_widgets' );
            }
        }
        return $sidebars_widgets;
    }
    
    add_filter('sidebars_widgets', 'disable_all_widgets', 1, 1);

    You don’t say if You want the full-width to all pages or only to topics, forums, or profiles.

    Regards,

    #177603
    crayc
    Participant

    I finally got it to go away like this

    if (is_bbpress ())

    if ( is_active_sidebar( ‘social-icons’ ) || is_active_sidebar( ‘click-here’ ) || is_active_sidebar( ‘split-sidebar-left’ ) || is_active_sidebar( ‘split-sidebar-right’ )) {

    but it removes it sitewide

    #177602
    crayc
    Participant

    It’s with the conditional, I have the sticky social icons on the right side on all my pages fixed. Don’t know if that is causing it to stay cause I just can’t seem to remove it from the forums pages, are there any alternatives to displaying a login section? As I said this genesis child theme does not have a registered sidebar, however I went in and registed the primary and secondary sidebar just so I could get the log in on there, but with that fixed widget in the way, it just pushes that sidebar off the left of the sticky widget.

    #177600
    crayc
    Participant

    thanks. I tried that and it did not work.
    I also tried
    if (!is_bbpress ())
    remove_action ( ‘genesis_after_header’, ‘the_411_extras’, ‘genesis_after_sidebar_widget_area’ );
    if ( is_active_sidebar( ‘social-icons’ ) || is_active_sidebar( ‘click-here’ ) || is_active_sidebar( ‘split-sidebar-left’ ) || is_active_sidebar( ‘split-sidebar-right’ )) {

    and
    if (!is_bbpress (‘forums’))

    if ( is_active_sidebar( ‘social-icons’ ) || is_active_sidebar( ‘click-here’ ) || is_active_sidebar( ‘split-sidebar-left’ ) || is_active_sidebar( ‘split-sidebar-right’ )) {

    with and without the forums part. nothing seems to remove it.

    #177566
    crayc
    Participant

    Hello, I am using genesis theme the-411 which has no sidebars just a fixed widget area to the right showing social icons. The site is forced full width but the container sit at about 800px I am trying to remove that from showing on the forums page and instead show a a login for bbpress. Not sure how to go about doing this. I tried the If conditional tag on there but it does not seem to work.

    here is the code
    //* Hook social icons and click here widget areas
    add_action( ‘genesis_after_header’, ‘the_411_extras’, ‘genesis_after_sidebar_widget_area’ );
    function the_411_extras() {

    if ( is_active_sidebar( ‘social-icons’ ) || is_active_sidebar( ‘click-here’ ) || is_active_sidebar( ‘split-sidebar-left’ ) || is_active_sidebar( ‘split-sidebar-right’ )) {

    echo ‘<div class=”site-extras”>’;

    genesis_widget_area( ‘social-icons’, array(
    ‘before’ => ‘<div class=”social-icons”>’,
    ‘after’ => ‘</div>’
    ) );

    genesis_widget_area( ‘click-here’, array(
    ‘before’ => ‘<div class=”click-here”>’,
    ‘after’ => ‘</div>’
    ) );
    genesis_widget_area( ‘split-sidebar-left’, array(
    ‘before’ => ‘<div class=”split-sidebar-left”>’,
    ‘after’ => ‘</div>’,
    ) );
    genesis_widget_area( ‘split-sidebar-right’, array(
    ‘before’ => ‘<div class=”split-sidebar-right”>’,
    ‘after’ => ‘</div>’,
    ) );

    echo ‘</div>’;

    if (is_bbpress( ‘forums’ ) ) {
    /** Remove default sidebar */
    remove_action( ‘genesis_after_sidebar_widget_area’ );
    }

    }

    }

    I added the split right and left, but I only use the right for search box. Thanks!

    majorholsety
    Participant

    I’ve spent a long time looking through fixes, and nothing has worked for me so far. Currently I am trying to set up a forum/website. I am using the Twenty Fifteen theme with bbPress, except I am currently on a child theme so I can make changes safely.

    The site portion looks fine, but the forum looks awkward:

    View post on imgur.com

    I would like to stretch out the forum side of this page so the posts take up more space. I don’t want to be scrolling constantly, especially with much larger posts. I think the best way to do this is removing the sidebar from the forum section. After the sidebar is gone, however, I don’t just want the right section to be centered and be the same size. I want it to take up the whole page. I understand this makes accessibility across the site a bit more difficult, but I can figure something out later.

    #175990
    IndigoO
    Participant

    EDITED: I first added the second code snippet you provided, then realized I needed to other one, so I deleted that second snippet and used the first at the end of the functions.php file in my child theme. It does not place a small “edit profile” link centered at the top of my forum main page, which is a help (thanks), but it also places the following text at the bottom of my members home page when logged in: “Click edit button to change this code.”

    That is not a clickable link and it is also not in the right location. Also, I can’t see where that specific text is being defined to edit the wording, which I’d want if it was a working link. It would be great to also have the edit link on the members home page, not just the forum main page, or even better to be able to add it to the sidebar that shows on all member area pages, but at least I’d like to remove this text from the non-forum page.

    Thanks in advance if you can sort this.

    #174934
    designbysue
    Participant

    That did not work. I still have the wrong widget showing up. The added page is displaying – I know because I added some text to test it, and even though I change the sidebar to the one I want the incorrect one is still showing up. I even tried to remove it and make the page full width and that did not work – the wrong sidebar is still there. Sure hope someone can help me solve this.

    Thanks
    Sue

    #173358
    stewmills
    Participant

    I have:
    WP 4.4.2
    bbPress 2.5.8
    BuddyPress 2.4.3
    Karma theme 3.0.3

    Please see my forum home page here: http://www.cytoviva.com/userforum/

    What I want to do is hide the “white area” with the logo and menu (products, gallery, etc.) ONLY on bbpress forum pages, not the rest of the non-forum pages. Here is the code for my bbPress.php page created from copying another template page and saving it in my child theme (as instructed).

    Can anyone tell me what to edit/remove from this page to just remove the home menu, but LEAVE the main top menu (home, about us, client sites) in blue?

    I have tried several things and can’t seem to get anywhere.

    Thanks in advance!!!

    <?php
    /*
    Template Name: bbPress
    */
    ?>
    <?php get_header(); ?>
    </div><!-- header-area -->
    </div><!-- end rays -->
    </div><!-- end header-holder -->
    </div><!-- end header -->
    
    <?php truethemes_before_main_hook();// action hook, see truethemes_framework/global/hooks.php ?>
    
    <div id="main">
    <?php get_template_part('theme-template-part-tools','childtheme'); ?>
    
    <div class="main-holder">
    <?php
    //retrieve value for sub-nav checkbox
    global $post;
    $post_id = $post->ID;
    $meta_value = get_post_meta($post_id,'truethemes_page_checkbox',true);
    
    if(empty($meta_value)){
    get_template_part('theme-template-part-subnav-horizontal','childtheme');
    }
    ?>
    
    <div id="content" class="content_left_sidebar">
    <?php if(have_posts()) : while(have_posts()) : the_post(); the_content(); truethemes_link_pages(); endwhile; endif;
    comments_template('/page-comments.php', true);
    get_template_part('theme-template-part-inline-editing','childtheme'); ?>
    </div><!-- end content -->
    
    <div id="sidebar" class="left_sidebar">
    <?php dynamic_sidebar('bbpress-custom-sidebar'); ?>
    </div><!-- end sidebar -->
    </div><!-- end main-holder -->
    </div><!-- main-area -->
    
    <?php get_footer(); ?>
Viewing 25 results - 1 through 25 (of 297 total)
Skip to toolbar