WordPress.org

Ready to get started?Download WordPress

Forums

[resolved] Finding Width for Single Posts (11 posts)

  1. mkirkwag
    Member
    Posted 3 years ago #

    Can anyone tell me where the width for a single post (as opposed to a page or the whole blog page) would normally be located in a theme and what it might say? I can't seem to find it. Thanks!

  2. xdesi
    Member
    Posted 3 years ago #

    The theme file for a Single Post is usually called "single.php", however the width would probably be defined in the CSS (usually style.css) for the page since CSS controls the presentation of the page.

    So you would be looking for the CSS class/ID which controls the single post width and then find it in the CSS and edit the width.

  3. mkirkwag
    Member
    Posted 3 years ago #

    What I was really asking was where in the style sheet...I've pored through the style sheet line by line and I can't find it...so I need to know what the class id is likely to be or what the usual language is that defines a single post. Just knowing that it should be there hasn't helped me because I'm so ignorant of what the code should be. It seems to me I've changed every possible thing related to "width" in the style sheet, but apparently not.

    There's nothing at all referring to "width" in single.php.

  4. xdesi
    Member
    Posted 3 years ago #

    Well you need to open up a single post page view the Source code from there and find/identify the element class/ID in question. There is no specific/convential naming, it could be anything.

    Obviously we can only help so far without seeing the page in question!

  5. mkirkwag
    Member
    Posted 3 years ago #

    Oh, sorry - I always put the page in...forgot!
    Here's a single post
    is the main page for comparison or the blog itself is here (since that's a static page):

    I'm trying to figure out why the sidebar is kicked out on the single posts only, and I'm thinking that width of the single post itself might be defined differently than the others.

  6. mkirkwag
    Member
    Posted 3 years ago #

    That came out odd.
    Here's a single post:
    http://tribeofadmins.com/eggcorns-and-malaprops
    and here's the blog page:
    http://tribeofadmins.com/tips-and-tricks-blog

  7. mkirkwag
    Member
    Posted 3 years ago #

    Hi...does anyone have time to look at this to see if you can tell what the class id is for single post width? I can't find it in the style sheet or in the single post.php...or anywhere else. My sidebar is getting bumped in single posts, and I'm wondering if I somehow changed the width of the posting area so that it's bumping the sidebar.
    Here's a single post:
    http://tribeofadmins.com/eggcorns-and-malaprops
    and here's the blog page:
    http://tribeofadmins.com/tips-and-tricks-blog

    Thanks in advance!

  8. xdesi
    Member
    Posted 3 years ago #

    Hi you are missing a closing DIV hence why the sidebar is dropping because it is still in the left content DIV if you understand, so you need to close this div before your sidebar.

    If this is only happening on posts then I guess you just need to add a </div> to the end of your single.php

  9. mkirkwag
    Member
    Posted 3 years ago #

    single.php begins
    <div id="sidebar" class="sidebars">
    and ends
    </div>
    Seems right, doesn't it?

  10. mkirkwag
    Member
    Posted 3 years ago #

    ignore that. sorry.

  11. mkirkwag
    Member
    Posted 3 years ago #

    Thanks! That did it. I found it in the middle of the single.php page. It's probably obvious from the above that I was looking at sidebar.php instead of single.php...I need a little red-faced emoticon here.

    Appreciate the help. I'm off to go read up on DIV

Topic Closed

This topic has been closed to new replies.

About this Topic