Viewing 12 replies - 1 through 12 (of 12 total)
  • Thread Starter NateJay

    (@natejay)

    Bump

    Can you post a link to a live site? It’s very difficult to diagnose these kinds of issues from just a screenshot.

    Thread Starter NateJay

    (@natejay)

    Currently the site is not live, it’s still in testing and have not bothered to have it hosted just yet. I figured the screenshot would be more than enough to show what the issue at hand is.

    I can provide code from the relevant .php files if you would prefer?

    I can see what the issue is, but it’s hard to know exactly what might be causing it without being able to see a live site. Have you tried adding some padding via CSS to the sidebar and the main content area?

    Thread Starter NateJay

    (@natejay)

    The sidebar and main content have background images applied to them, unfortunately I cannot add a padding to either of them because the images move and bring the sidebar text/posts with them.

    That’s a bit unusual. Can you post your CSS to Pastebin and post a link here?

    Thread Starter NateJay

    (@natejay)

    Does it work if you set box-sizing to border-box, instead of content-box:

    #wrapper { box-sizing: border-box; }
    
    #sidebar { box-sizing: inherit; }
    #contentbox { box-sizing: inherit; }
    Thread Starter NateJay

    (@natejay)

    Works perfectly as you can see:

    http://prntscr.com/6vvpnb

    Only issue is that the posts in the contentbox are bunched up together. Any idea how I can create spacing between the posts?

    Some of these things you should be learning in class. 😉

    Are you giving each post its own container (<div>...</div> or <article>...</article> or whatever) in your loop? You could apply some bottom margin to each container.

    Thread Starter NateJay

    (@natejay)

    Oh I have been learning most of the .css, its the jump from regular web development to WordPress that has me stumped.

    I didn’t think to give it its own container. (Something I wasn’t taught, unfortunately)

    http://pastebin.com/DxxHBKc0Index

    I’m assuming this code needs to have .css rules applied somewhere.

    According to the paste you posted, each individual post is enclosed within <article> tags. If you checked the source of your site (using Firebug or some other web inspecting tool), you’ll see something like this:

    <div id="contentbox">
      <article>...</article>
      <article>...</article>
      <article>...</article>
    </div>

    Each of those <article>...</article> pairs contains one post.

    In your stylesheet, something like this should work:

    #contentbox article {
    margin-bottom: 30px;
    }

    You might benefit from reading this page: https://codex.wordpress.org/Theme_Development. Also, there are some starter themes out there that will give you an idea of how WP themes are put together: _s, Bones

Viewing 12 replies - 1 through 12 (of 12 total)
  • The topic ‘Sidebar text and index content loop text too far left’ is closed to new replies.