WordPress.org

Ready to get started?Download WordPress

Forums

Sidebar is showing up at the bottom of page on single.php (18 posts)

  1. VBPartners
    Member
    Posted 3 years ago #

    on www. careerpotential.com/blog/how-to-deal-with-annoying-co-workers-part-2-of-2/, for example, the sidebar is at the bottom of the page.

    i've played around with the various margins, etc. but can't get it to show at the top next to the post.

    any suggestions? or tips?

    thanks!

  2. Samuel B
    moderator
    Posted 3 years ago #

  3. FishDogFish
    Member
    Posted 3 years ago #

    #sidebar
    {
    padding: 20px 0 10px 0;
    margin-left: 545px;
    width: 190px;
    }

    All that left margin is bound to break the layout.

    Get rid of the left margin and float the sidebar left.

    Change it to.

    #sidebar
    {
    padding: 20px 0 10px 0;
    margin-left: 5px;
    width: 190px;
    float:left;
    }

  4. benjamin
    Member
    Posted 3 years ago #

    I took and look and not completely sure. After cleaning up the errors, if you are still having problems, here are my thoughts:

    1. If you are using widgets, try turning them off and see how the default code appears.

    2. Try widening your main column and if that doesn't work try changing the nested div order and see the results.

    Hope that helps

  5. VBPartners
    Member
    Posted 3 years ago #

    Thanks for the feed back and tips.

    As far as the errors - really appreciate that link. I looked through the errors and tried to find them within my php files, but can't seem to locate them.

    How/where do you go to fix them?

    I can identify the problems in 'view source', but where within my WP files do i go to fix them?

    any suggestions would be greatly appreciated...

  6. Samuel B
    moderator
    Posted 3 years ago #

    the major problem is in theme's header.php looks like

  7. VBPartners
    Member
    Posted 3 years ago #

    thanks for pointing me in the right direction....

    hate to admit, i'm still a bit lost... still dont see those errors in the header.php file.

  8. Samuel B
    moderator
    Posted 3 years ago #

    for one thing, validator shows head tag way too late - like maybe it was moved?
    usually <head> is in header.php soon after DOCTYPE declaration

  9. FishDogFish
    Member
    Posted 3 years ago #

    Those errors aren't what's breaking your layout.

    The extra 545 pixels on the left side of your sidebar is what's breaking the layout.

    I'd fix that before digging around in the php files, because more than likely it's a plugin or something causing the validation service to throw errors.

  10. VBPartners
    Member
    Posted 3 years ago #

    thanks for the tip...

    i dont see, though, where the 545 pixels are... i searched the style.csc and can't find it.

    can you tell me where it is that i need to make a change?

    thanks again for the help!

  11. FishDogFish
    Member
    Posted 3 years ago #

    If my help isn't appreciated I won't offer it to you anymore.

  12. VBPartners
    Member
    Posted 3 years ago #

    Sorry if i some how offended you...

    i had thanked you twice in my post and i meant it sincerely... i really do appreciate your help... not sure what i said wrong.

    anyways, all i was asking is where to find the setting where i could change the 545 pixels... i looked but wasnt able to find it.

  13. FishDogFish
    Member
    Posted 3 years ago #

    Here, read This

  14. VBPartners
    Member
    Posted 3 years ago #

    Hi again...

    I had tried that and it's still not quite right. The coding you suggested stated "float: left", which I changed to right so that it would be on the right hand side.

    It's still down below the content.

    I've been able to fix similar problems before on other themes... dont know why this one is giving such trouble.

    thanks again for your time, appreciate it.

  15. FishDogFish
    Member
    Posted 3 years ago #

    I forgot to mention, you probably need to float the content div left also, that way both will be side by side.

    Something you can check is the width of your container div, the one that holds your content and sidebar divs, and make sure that it's big enough to hold the width of the content div and the sidebar added together.

    If it's not you can enlarge the container, or adjust the content and/or sidebar div/s to fit in the container.

    Don't forget to include any left and right margin that is set on the content and sidebar, also check for padding on the container. Normally wouldn't expect that, but since the sidebar had 545 pixels of margin on it I'd be suspicious of the other divs.

  16. FishDogFish
    Member
    Posted 3 years ago #

    Find this div

    .widecolumn {
    padding: 10px 0 20px 0;
    margin: 5px 0 0 20px;
    width: 450px;
    }

    And try changing it to

    .widecolumn {
    padding: 10px 0 20px 0;
    margin: 5px 0 0 20px;
    width: 450px;
    float:left;
    }

    Also make sure you float the sidebar left, and remove the left margin.

    They should line up side by side.

  17. VBPartners
    Member
    Posted 3 years ago #

    Well, you did it! You found what was not allowing the sidebar to show up at the top. Thanks :)

    Really appreciate all of the time it took for you to look into this problem for me and offer me your assistance.

    Sincerely appreciate it :)

  18. FishDogFish
    Member
    Posted 3 years ago #

    Glad to see it's working.

    Now you can mark this problem "Resolved".

Topic Closed

This topic has been closed to new replies.

About this Topic