• Skip to primary navigation
  • Skip to main content
  • Skip to primary sidebar

WP SITES

2785

Original Genesis & WooCommerce Tutorials & 6000+ Guaranteed Code

Snippets

  • Try Premium
  • Log in

Change Layout On Posts, Pages & Archives in Genesis

There’s many ways to change the layout options on posts, pages and archives. The only problem is, you either have to change them manually, one by one using the Layout Settings on all edit post/page screens, or change them site wide using the Genesis > Theme Settings > Default Layout settings.

What if you want to change them only on single posts or only on pages. What if you want to change the layout on all archive pages for a specific category or all archives?

single post & page layout options

In this tutorial, i’ll provide you with custom functions which you can simple paste at the end of your child themes functions.php file using a text editor like Notepad++.

You can also change the conditional tag and the layout option using these settings.

  • content-sidebar
  • sidebar-content
  • content-sidebar-sidebar
  • sidebar-sidebar-content
  • sidebar-content-sidebar
  • full-width-content

Full Width Layout On Single Posts

Full Width Layout On All Archives

Includes category, tag, author and date based archive pages.

Full Width Layout On All Pages

Full Width Layout On All Posts In A Category

Find your category i.d and replace 007 or use the category name or category-slug instead.

Not Working?

  1. This code won’t override files like front-page.php, home.php, page_landing.php, single-portfolio.php, archive-portfolio.php and other templates which include code to force a specific layout in the template. Simply change the code in the template which changes the layout to do that.
add_filter( 'genesis_site_layout', '__genesis_return_full_width_content' );
  1. Also, if you install a plugin which changes the layouts, it may override any code you use to do the same thing.

  2. Another reason the code may not do what you want it to is if it contains the wrong conditional tag.

Example: The code containing the is_single() conditional tag only changes the layout on single posts.

Layout Plugins

If you prefer plugins to code, you’re in luck.

The Genesis Layout Extra plugin enables you to:

Modify the default layouts for homepage, singular, archive, attachment, search, 404 and even bbPress via the Genesis theme settings page.

Layout

Reader Interactions

Comments

  1. Angie says

    November 12, 2014 at 12:48 pm

    I’m kind of having the opposite problem as addressed here. My site is pretty much all full-width, but my blog page is too wide, there are too many words on each line making it hard to read. I have other pages on my site that use posts archives and they look fine, so I don’t want to change the width of archive pages, just posts with the category called “blog” and make them less wide. Is there any way to accomplish this?

    Log in to Reply
    • Brad Dalton says

      November 12, 2014 at 1:16 pm

      Hello Angie

      You shouldn’t create a category named blog as it may cause problems.

      I would change it to news or something like that then you can use the code in this post.

      Log in to Reply
  2. fay says

    December 28, 2013 at 5:01 pm

    Would love to create a single post layout like this http://www.thecoveteur.com/13-best-2013-chiara-ferragni-part-two/

    an ideas? So full width at the top with sidebar after post content.

    Log in to Reply
    • Brad Dalton says

      December 28, 2013 at 5:51 pm

      Can be done if you know how to code a custom page template http://wpsites.net/web-design/flexible-responsive-widgets-template-for-genesis/

      Log in to Reply
      • fay says

        December 28, 2013 at 5:56 pm

        Amazing! Have been searching for hours but that looks like a good starting point. I know a fair about genesis so should be able to work it out from there.

        Thanks for such a speedy reply 😀 and Happy New Year!

        Log in to Reply
        • Brad Dalton says

          December 28, 2013 at 6:00 pm

          You could also use a custom post type portfolio style archive which is 3 columns width with or without a sidebar http://wpsites.net/web-design/add-portfolio-page-to-modern-portfolio-pro-theme/

          Not as flexible but enables you to also add custom taxonomy types.

          Log in to Reply

Leave a Reply Cancel reply

You must be logged in to post a comment.

Primary Sidebar

Code written by Brad Dalton specialist for Genesis, WooCommerce & WordPress theme customization. Read More…

Advertise · WPEngine · Genesis · Log in

  • Access Problems
  • Account Details
  • Consulting
  • Tags
 

Loading Comments...
 

You must be logged in to post a comment.