WordPress.org

Ready to get started?Download WordPress

Forums

Ari
Remove Right Sidebar from Page (9 posts)

  1. Mark
    Member
    Posted 1 year ago #

    Hello. I would like to remove the right sidebar from my page here:
    http://www.runspotrun.com/portfolio

    Thanks!
    M ark

    http://wordpress.org/extend/themes/ari/

  2. Digest WP
    Member
    Posted 1 year ago #

    Just comment out the sidebar include from the template

    It looks like this

    <?php get_sidebar(); ?>
  3. Mark
    Member
    Posted 1 year ago #

    This is great - thanks!

    But how do I widen the content area on my Page now to use the right rail space that I've gained?

  4. Digest WP
    Member
    Posted 1 year ago #

    This is the CSS controlling that.

    #content {
    width: 62.5%;
    margin: 0px 0px 60px 0px;
    padding: 0px 0px 0px 60px;
    float: left;
    font-size: 14px;
    }

    You will have to adjust the width %

  5. Mark
    Member
    Posted 1 year ago #

    Won't this change the width on posts as well?

  6. Digest WP
    Member
    Posted 1 year ago #

    Hey, sorry I was assuming the sidebar would be gone on all pages and posts.

    Add a width to this style then like in this example. That only controls pages and not posts and I think will still work with being responsive since the content is using a %

    #page {
    margin-bottom: 50px;
    width: 650px;
    padding: 0px 0px 6px 0px;
    border-bottom: 1px dotted #4C4C4C;
    }
  7. alchymyth
    The Sweeper & Moderator
    Posted 1 year ago #

    the theme uses body_class() which outputs page specific css classes;
    you can use those to selectively change the formatting on the one page only;

    example (for your portfolio page):

    .page-id-1446 #main {
    width: 100%;
    }
  8. Mark
    Member
    Posted 1 year ago #

    @alchymyth - Gave this a shot, but the results aren't so great:
    http://www.runspotrun.com/portfolio

  9. alchymyth
    The Sweeper & Moderator
    Posted 1 year ago #

    my comment only referred to applying the right formatting for a specific page;

    you still need to remove the sidebar for that page, possibly by creating a page template http://codex.wordpress.org/Pages#Page_Templates (just a copy of page.php with the necessary extra coding at the top, where you remove the <?php get_sidebar(); ?> line.

    plus more formatting with possible changes to other styles to stretch the content (which will then scroll through the site title and tag line ...)

    'the devil is in the detail'

    a bunch of extra useful css:

    .page-id-1446 #sidebar-primary .sidebar { display: none; }
    .page-id-1446 #sidebar-primary { background: #fff; padding-top:20px;margin-top:-20px; }
    .page-id-1446 #main { width:100%; }
    .page-id-1446 #content { width:95%; }
    .page-id-1446 #page { width:94%; }

    the first line of those does virtually the same job as creating a page template - it hides the sidebar.

Topic Closed

This topic has been closed to new replies.

About this Theme

About this Topic

Tags