• Skip to main content
  • Skip to forum navigation

StudioPress

  • Shop for Themes
  • My StudioPress

Forum navigation

  • Home
  • General Genesis Discussions
  • StudioPress Themes
  • Genesis Blocks
    • Genesis Blocks
    • Genesis Custom Blocks
  • Retired Themes
  • FAQs
  • Forum Rules
  • Internationalization and Translations
  • Forum Bugs and Suggestions
  • Forum Log In

Are You Using The WordPress Block Editor?

Genesis now offers plugins that help you build better sites faster with the WordPress block editor (Gutenberg). Try the feature-rich free versions of each plugin for yourself!

Genesis Blocks Genesis Custom Blocks

Disable sidebar on select posts in Outreach Pro?

Welcome!

These forums are for general discussion on WordPress and Genesis. Official support for StudioPress themes is offered exclusively at My StudioPress. Responses in this forum are not guaranteed. Please note that this forum will require a new username, separate from the one used for My.StudioPress.

Log In
Register Lost Password

Community Forums › Forums › Archived Forums › Design Tips and Tricks › Disable sidebar on select posts in Outreach Pro?

This topic is: not resolved

Tagged: disable, posts, Sidebar

  • This topic has 19 replies, 3 voices, and was last updated 9 years ago by styzer.
Viewing 20 posts - 1 through 20 (of 20 total)
  • Author
    Posts
  • September 7, 2014 at 7:52 pm #123261
    styzer
    Participant

    Hi all,

    I'd like to disable the sidebar (it's on the right side) on certain pages. For example, I have embedded a PDF document, so it needs more elbow room. I tried Brad's code () but it didn't work. Unless I misunderstood and I have to edit TWO files? I only added the CSS code with the postid to the style.css.

    I can see a layout selection on the pages admin, but not for the posts. Is this normal?

    Thanks!

    Andre

    http://ortzion.org/prophecy_type/gods-unchangeable-calendar/
    September 7, 2014 at 8:29 pm #123266
    Anita
    Keymaster

    You can do that by selecting the Full Width Layout on the Page or Post itself. If you don't see layouts, then go up to Screen Options on a Page or Post, select Layouts and it will show up. No need for any special coding.


    Love coffee, chocolate and my Bella!

    September 7, 2014 at 8:53 pm #123272
    styzer
    Participant

    Thank you Anita,

    Yes, that's what I thought, but there is no "layouts" options for the posts in the Outreach Pro theme. Here is what I have:

    Revisions - Excerpt - Send Trackbacks - Custom Fields - Discussion - Comments - Slug - Author - Mega Main Options - Categories - Tags - Attributes - Featured Image

    How would I add the "layout" option there?

    Thanks!

    September 7, 2014 at 9:10 pm #123276
    Anita
    Keymaster

    You should see this on both pages and posts. Did you design the site yourself? Sometimes developers will hide theme settings. If you still do not see the Layouts - go to your user profile. Scroll down and check to see if you have Layout settings there. You don't need to do anything there - just look to see if it's there. If you don't, then there may be some code in your Functions.php file that is hiding it.


    Love coffee, chocolate and my Bella!

    September 7, 2014 at 9:14 pm #123277
    styzer
    Participant

    Yes, I see it there.

    Layout Settings
    These settings apply to this author's archive pages.
    Choose Layout
    Default Layout set in Theme Settings

    September 7, 2014 at 9:38 pm #123282
    Anita
    Keymaster

    But you don't see it anywhere on your pages and posts - when you are in Edit mode? Scrolled all the way to the bottom? It's not there?


    Love coffee, chocolate and my Bella!

    September 7, 2014 at 9:40 pm #123283
    styzer
    Participant

    It's only there on the PAGES, but not on the POSTS in edit mode. That's what I find strange. I'm used to use this function, so why isn't it showing? M-y-s-t-e-r-y... 🙂

    September 7, 2014 at 9:43 pm #123285
    Anita
    Keymaster

    Can you add a screen shot of your full screen in here?


    Love coffee, chocolate and my Bella!

    September 7, 2014 at 10:09 pm #123287
    styzer
    Participant

    OK, so here is the EDIT page.

    screenshot edit Page

    September 8, 2014 at 5:39 am #123337
    Anita
    Keymaster

    Go back to Brad's tutorials. You are using a Custom Post Type which requires an additional code. So go back to Brad's code, whatever that may be, and look for the instructions for adding that part.


    Love coffee, chocolate and my Bella!

    September 8, 2014 at 11:12 am #123410
    styzer
    Participant

    Hi Anita,

    Thank you for the reply.

    So are you saying I should be adding TWO codes, one php and one css?

    Regards,

    Andre

    September 8, 2014 at 11:14 am #123413
    Anita
    Keymaster

    I am not sure. I don't know what code you used by Brad to do what you've done. Go back to his tutorial and re-read his instructions.


    Love coffee, chocolate and my Bella!

    September 8, 2014 at 11:19 am #123419
    styzer
    Participant

    This is the code Brad shares:
    http://wpsites.net/web-design/remove-sidebar-home-page-posts/

    I don't know how to interpret it, though.

    September 8, 2014 at 11:31 am #123425
    Craig
    Member

    Can you try adding this line to your functions.php file styzer. You will need to replace 'your_custom_post_type' with the name given to your 'Prophecy' post type.

    add_post_type_support( 'your_custom_post_type', 'genesis-layouts' );


    @craigsimps | craigsimps.com

    September 8, 2014 at 11:45 am #123431
    styzer
    Participant

    Thanks Craig,

    Here is where I added it:

    // Register Custom Post Type
    function prophecy_post_type() {
    
    add_post_type_support( 'prophecy_post_type', 'genesis-layouts' );
    
    	$labels = array(
    		'name'                => _x( 'Prophecy Types', 'Post Type General Name', 'prophecy' ),
    		'singular_name'       => _x( 'Prophecy', 'Post Type Singular Name', 'prophecy' ),
    		'menu_name'           => __( 'Prophecy', 'prophecy' ),
    		'parent_item_colon'   => __( 'Parent Item:', 'prophecy' ),
    		'all_items'           => __( 'All Items', 'prophecy' ),
    		'view_item'           => __( 'View Item', 'prophecy' ),
    		'add_new_item'        => __( 'Add New Item', 'prophecy' ),
    		'add_new'             => __( 'Add New', 'prophecy' ),
    		'edit_item'           => __( 'Edit Item', 'prophecy' ),
    		'update_item'         => __( 'Update Item', 'prophecy' ),
    		'search_items'        => __( 'Search Item', 'prophecy' ),
    		'not_found'           => __( 'Not found', 'prophecy' ),
    		'not_found_in_trash'  => __( 'Not found in Trash', 'prophecy' ),
    	);
    	$args = array(
    		'label'               => __( 'prophecy_type', 'prophecy' ),
    		'description'         => __( 'Prophecy Type Description', 'prophecy' ),
    		'labels'              => $labels,
    		'supports'            => array( 'title', 'editor', 'excerpt', 'author', 'thumbnail', 'comments', 'trackbacks', 'revisions', 'custom-fields', 'page-attributes', 'post-formats', ),
    		'taxonomies'          => array( 'category', 'post_tag' ),
    		'hierarchical'        => false,
    		'public'              => true,
    		'show_ui'             => true,
    		'show_in_menu'        => true,
    		'show_in_nav_menus'   => true,
    		'show_in_admin_bar'   => true,
    		'menu_position'       => 5,
    		'menu_icon'           => '',
    		'can_export'          => true,
    		'has_archive'         => true,
    		'exclude_from_search' => false,
    		'publicly_queryable'  => true,
    		'capability_type'     => 'page',
    	);
    	register_post_type( 'prophecy_type', $args );
    }
    
    // Hook into the 'init' action
    add_action( 'init', 'prophecy_post_type', 0 );

    I also have this in my style.css:

    .postid-6113 #sidebar {
    display: none;
    }

    But when I go to my EDIT page for this post, I still don't see any layout options. What am I missing?

    Regards,

    Andre

    September 8, 2014 at 11:48 am #123432
    Craig
    Member

    Hi, could you try moving it out of the prophecy_post_type() function, and place it just after your add_action, so it looks like:

    // Register Custom Post Type
    function prophecy_post_type() {
    
    	$labels = array(
    		'name'                => _x( 'Prophecy Types', 'Post Type General Name', 'prophecy' ),
    		'singular_name'       => _x( 'Prophecy', 'Post Type Singular Name', 'prophecy' ),
    		'menu_name'           => __( 'Prophecy', 'prophecy' ),
    		'parent_item_colon'   => __( 'Parent Item:', 'prophecy' ),
    		'all_items'           => __( 'All Items', 'prophecy' ),
    		'view_item'           => __( 'View Item', 'prophecy' ),
    		'add_new_item'        => __( 'Add New Item', 'prophecy' ),
    		'add_new'             => __( 'Add New', 'prophecy' ),
    		'edit_item'           => __( 'Edit Item', 'prophecy' ),
    		'update_item'         => __( 'Update Item', 'prophecy' ),
    		'search_items'        => __( 'Search Item', 'prophecy' ),
    		'not_found'           => __( 'Not found', 'prophecy' ),
    		'not_found_in_trash'  => __( 'Not found in Trash', 'prophecy' ),
    	);
    	$args = array(
    		'label'               => __( 'prophecy_type', 'prophecy' ),
    		'description'         => __( 'Prophecy Type Description', 'prophecy' ),
    		'labels'              => $labels,
    		'supports'            => array( 'title', 'editor', 'excerpt', 'author', 'thumbnail', 'comments', 'trackbacks', 'revisions', 'custom-fields', 'page-attributes', 'post-formats', ),
    		'taxonomies'          => array( 'category', 'post_tag' ),
    		'hierarchical'        => false,
    		'public'              => true,
    		'show_ui'             => true,
    		'show_in_menu'        => true,
    		'show_in_nav_menus'   => true,
    		'show_in_admin_bar'   => true,
    		'menu_position'       => 5,
    		'menu_icon'           => '',
    		'can_export'          => true,
    		'has_archive'         => true,
    		'exclude_from_search' => false,
    		'publicly_queryable'  => true,
    		'capability_type'     => 'page',
    	);
    	register_post_type( 'prophecy_type', $args );
    }
    
    // Hook into the 'init' action
    add_action( 'init', 'prophecy_post_type', 0 );
    add_post_type_support( 'prophecy_type', 'genesis-layouts' );

    @craigsimps | craigsimps.com

    September 8, 2014 at 11:55 am #123435
    styzer
    Participant

    THAT'S IT!!!

    That was the missing piece. So when we create custom posts type hard-coding the functions.php file, it is important to include this snippet of code we we gain the same options as regular posts.

    I will add this to my other custom post types.

    Thanks again Anita, and Craig!

    Andre

    September 8, 2014 at 12:00 pm #123437
    Craig
    Member

    Yes, likewise there is a similar addition required if you want to include the Genesis SEO settings. For reference, it is

    add_post_type_support( 'your_custom_post_type', 'genesis-seo' );


    @craigsimps | craigsimps.com

    September 8, 2014 at 12:03 pm #123438
    styzer
    Participant

    Thanks Craig, I'll make sure to add this too.

    Regards,

    Andre

    September 8, 2014 at 12:04 pm #123439
    styzer
    Participant
    This reply has been marked as private.
  • Author
    Posts
Viewing 20 posts - 1 through 20 (of 20 total)
  • The forum ‘Design Tips and Tricks’ is closed to new topics and replies.

CTA

Ready to get started? Create a site or shop for themes.

Create a site with WP EngineShop for Themes

Footer

StudioPress

© 2023 WPEngine, Inc.

Products
  • Create a Site with WP Engine
  • Shop for Themes
  • Theme Features
  • Get Started
  • Showcase
Company
  • Brand Assets
  • Terms of Service
  • Accptable Usse Policy
  • Privacy Policy
  • Refund Policy
  • Contact Us
Community
  • Find Developers
  • Forums
  • Facebook Group
  • #GenesisWP
  • Showcase
Resources
  • StudioPress Blog
  • Help & Documentation
  • FAQs
  • Code Snippets
  • Affiliates
Connect
  • StudioPress Live
  • StudioPress FM
  • Facebook
  • Twitter
  • Dribbble