Archived topic
Changing page width for single page
5 replies · Started by Daniel on January 14, 2023
Hi there
A bit of background info:
- My pages are all 800 width with no sidebar. This is set in the global settings and I don't want to change this.
I want to create a custom page for a single post. I want it to have a width of 1200 pixels and a sidebar (included in that width).
I have done this using the layout element with the settings: full width and 1200 content width. That seems to work but for some reason the sidebar gets pushed below the content. It is not to the right of the content on desktop.
Could someone help?
Cheers!
Dan
Hi Dan,
The layout element can only change the content width to be a smaller number and not larger.
Is it just for a single page/post? If so can you link me to it and we'll just use CSS for this one?
Thanks :)
Hi Leo. Thanks for the fast reply.
Here is the URL:
https://drawpaintacademy.com/composition_v2/
Ideally the width would be 1200 pixels.
Cheers!
Dan
This should work:
.single-post.postid-29831 .site.grid-container {
max-width: 1200px;
}
Adding CSS: https://docs.generatepress.com/article/adding-css/
Make sure to clear you caching plugin.
Let me know if this helps :)
You are amazing! Thanks!
No problem :)