Site logo

Archived topic

how to use different container size for content (no sidebar)

5 replies · Started by mishal on March 12, 2019

Viewing posts 1–6 of 6

Hello there,

I want to use the different type of container for my blog post, means I want to write my some blog posts in content/sidebar layout and some blog post in content (no sidebar) layout. My question is, How can I use the different container size for both layouts?

Thank You🙂

Hi there,

so do you want to change the entire container width when there is no sidebar or just the_content ?

For example this CSS will reduce the content area of the post with no sidebars:

.single-post.no-sidebar #main {
    max-width: 680px;
    margin-left: auto;
    margin-right: auto;
}

Thanks David, It's working.

Glad to be of help.

Hi David,
Thanks for your CSS. I had a similar issue.
Another quick question on the same.. I want to also reduce the width for some of my pages (not all). How can I do that?
For example, I want to reduce the width for my about & contact pages too (as the text on these looks far too wide), but not on my home page or archive pages.
How can I go about it?

Any chance you can open a new topic for the question?

Thanks :)

This archived topic is closed to new replies.