WordPress.org

Ready to get started?Download WordPress

Forums

Writr
[resolved] How to alter text width in posts (4 posts)

  1. bretticusrex
    Member
    Posted 7 months ago #

    Hi,

    I have been trying with no success to make my pages on this theme a little wider and it is confusing me. I have changed the page width under this section of code:

    /* Primary */
    .content-area {
    	float: right;
    	width: 540px;
    	height: auto;
    	padding: 0 40px;
    	-webkit-box-sizing: border-box;
    	-moz-box-sizing:    border-box;
    	box-sizing:         border-box;
    }

    Everything is 540px and I want something more like 800px, so changing this made the width of the article wider.

    Then this code:

    /* Grid */
    #page {
    	position: relative;
    	z-index: 1;
    	margin: 0;
    	width: 940px;
    }
    #page:before {
    	content: '';
    	display: block;
    	position: fixed;
    	z-index: -1;
    	top: 0;
    	left: 400px;
    	width: 540px;
    	height: 100%;
    	background: #fff;
    }

    allows you to change the width of the content, but when I change the (I believe) correct section under page:before width to something larger (say 800px, and I tried this with the content-area width larger than this number) it does make it wider, but it also ruins the positioning and places it lower and farther left, maybe because it is placed "relative," but relative to what? Isn't that something that is in the html code and not the CSS? I am confused. Please help.

  2. Hi there, this theme actually has a wider page layout already built in. You can select it under Appearance > Customize.

    Click the Theme Options tab, and check the box next to "Wider Content Area."

    Let me know if that does the trick!

  3. bretticusrex
    Member
    Posted 7 months ago #

    Wow, that makes me feel stupid. Yes, that did the trick! Thanks.

    Now when I look at the CSS, the two areas I mentioned are the same, which confuses me, but maybe that will be a question for another life when I make websites.

  4. No need to feel stupid. :-)

    The wider CSS is being served from this file:

    http://brettschager.com/wp-content/themes/writr/css/wider.css

Reply

You must log in to post.

About this Theme

About this Topic