Removing 3rd column on single post display

  • shnibitdohget

    #4279

    Great theme, thanks for your work!

    I’m using the 3 column view, with content in the center. I’d like to remove the right column in a single post view though. How would I do that?

    shnibitdohget

    #27790

    Ok, figured it partly out… Made a header-single.php (as this was the only place I saw a get sidebar command, changed 185-192 to:

    /* Sidebar2 on the left side? */
    if ( in_array( graphene_column_mode(), array( 'three-col-right', /* 'three-col-center', */'two-col-right' ) ) ){
    get_sidebar( 'two' );
    }

    /* Sidebar1 on the left side? */
    if ( in_array( graphene_column_mode(), array( 'three-col-right', 'three-col-center' ) ) ){
    get_sidebar();

    On single.php I changed the header to get the header-single.php file… However, this displays the primary sidebar on the left, instead of the secondary. So now I just need to fix that and adjust the width of the single post display.

    shnibitdohget

    #27791

    Ok, edited single.php lines 25-26 to say,

    if (!is_front_page() && is_active_sidebar('sidebar-widget-area')) { // Not home, display normal sidebar if active
    dynamic_sidebar('sidebar-two-widget-area');

    That fixed the sidebar issue, now I just need to fix the single post width display…

    shnibitdohget

    #27792

    Scratch all that… obviously going around my arse to get to my elbow. Try this instead:

    .single-post #content-main {
    width: 675px;
    }

    .single-post #sidebar1 {
    display: none;
    }
Viewing 4 posts - 1 through 4 (of 4 total)

You must be logged in to reply to this topic.

Do NOT follow this link or you will be banned from the site!