WordPress.org

Ready to get started?Download WordPress

Forums

Twenty Fourteen
Extend content width for one page only (7 posts)

  1. nicomorgan
    Member
    Posted 6 months ago #

    I would like a way to make the content wider on a single page. It is set to full width but obviously restricted by the max-width property, which leaves a lot of blank space around the content at the moment. I want to override that and make it 90%.

    I don't want to change this property site-wide, but just for this one page (and any subsequent one which need the extra width!).

    Is there a custom css method which can be attached to a single page?

  2. kaniamea
    Member
    Posted 6 months ago #

    Find the POST ID of the page you would like to modify and extend the width by adding this to your Custom CSS:

    .page-id-49 // this is an example post-id {
    width: 1200px; // or the width you like
    }
  3. nicomorgan
    Member
    Posted 6 months ago #

    Thank you kaniamea but I couldn't get this to work.

    As far as I can see the page-id-449 (in my case) class is applied to the body tag.

    There is a post-449 id which is applied to the article tag as well. I tried adding this to the custom css:
    .page-id-449 {
    width: 1038px;
    }

    article#post-449 .entry-content {
    width: 1200px;
    }

    but something is still overriding the width:

    http://blog.nicomorgan.com/the-store/

  4. kaniamea
    Member
    Posted 6 months ago #

    Ok try replacing:

    .page-id-449 {
    width: 1038px;
    }

    with

    .page-id-449 {
        width: 1200px;
    }
  5. nicomorgan
    Member
    Posted 6 months ago #

    OK, tried that, but nothing looks different:
    http://blog.nicomorgan.com/the-store/

    It still cuts off half of the banner as you can see. It certainly isn't using the whole 1200px we have specified.

  6. esmi
    Forum Moderator
    Posted 6 months ago #

    Are you using a child theme or a custom CSS plugin?

  7. nicomorgan
    Member
    Posted 6 months ago #

    Hi Esmi

    Neither actually. I'm using the custom css file in the main theme. Does this make any difference?

Reply

You must log in to post.

About this Theme

About this Topic