• Resolved electriX

    (@sgarbus)


    I’m trying to remove the sidebar on my site for just the homepage. I realize it’s located in home.php. Is there any easy way to go about removing the container that’s still remains for the sidebar? Or are there already styles on a different page that I could use? I tried using the full-width template on home.php but that didn’t work.

    I’d like to stretch the posts full-width, then my plan is to increase columns to 4-5 instead of 2. Every time I tried removing the sidebar and getting that container to disappear, the posts would only stretch 2 wide. Or still be constricted to the ‘left’ container (ie: I had a 5-column setup but there was blank space on the sidebar area still)

    Just trying to find to easiest and most efficient way possible while retaining the post box styles.

    Thanks,

    • This topic was modified 5 years, 12 months ago by electriX.

    The page I need help with: [log in to see the link]

Viewing 3 replies - 1 through 3 (of 3 total)
  • Thread Starter electriX

    (@sgarbus)

    Thought I figured it out but turns out it would be a style nightmare ??

    I think this may get you off to a start

    .home #primary {
        width: 100%;
    }
    .home .site-content {
        display: block;
    }
    .home #secondary {
        display: none;
    }
    @media only screen and (min-width: 1100px) {
        .blog-grid-layout .content-archive .post-wrapper {
            grid-template-columns: 1fr 1fr 1fr 1fr;
        }
    }

    Seems to work from minor testing on my local PC and reverts back to 2 columns when the browser width is less than 1100px wide

    Theme Author ThemeZee

    (@themezee)

    Hi there,

    Thanks so much for using Donovan.

    The code from Jarret should work fine.

    You should also be able to adjust the layout with this CSS snippet if you only want to remove the sidebar on the home page:

    .home .site-content {
        display: block;
    }
    
    .home .sidebar {
        display: none;
    }

    Cheers,
    Thomas

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘Easy way to remove homepage sidebar?’ is closed to new replies.