Grow your CSS skills. Land your dream job.

Float issue on html5 reset wordpress theme

  • # March 25, 2013 at 11:36 am

    Hello.

    I’m using the html5 reset wordpress theme and I’m having problems to create a simple float using the page.php template. Here is the code I’m using:

    article.post,
    #respond{
    width:700px;
    float:left;
    background:blue;
    }

    #sidebar{
    float:right;
    width:250px;
    background:red;
    }

    Here is a screenshot of the result.
    [Screenshot](http://quartoestudio.com/shots/css-float-issue.png “css float issue”)

    Any idea to solve this? Thanks!

    # March 25, 2013 at 11:57 am

    what’s the problem? where’s the code? Help us help you

    # March 25, 2013 at 12:48 pm

    Sorry about that wolfcry911… Here is the code:

    Here is [the code](http://pastebin.com/K31UaV3c “”)

    # March 25, 2013 at 12:54 pm

    Please make a reduced case Codepen with HTML & CSS…we really don’t need all that other extraneous stuff.

    # March 25, 2013 at 1:06 pm

    Thanks for the tip Paulie_D, I didn’t know the Codepen :)

    http://codepen.io/evandropastor/pen/Ijzck

    I’ve marked the problematic code like so:

    < ! --- problematic code--- >

    # March 25, 2013 at 1:16 pm

    Franly, there is still too much extraneous code in there.

    However, what I think you need to do is separate out all the content that you want to have appear in the left side of the page and wrap that in a div that is then floated left.

    Like this: http://codepen.io/Paulie-D/pen/rnche

    # March 25, 2013 at 1:55 pm

    Paulie_D thanks for the tip! It works! I’ve inserted a div like so:

    < ?php comments_template(); ?>
    < ?php endwhile; endif; ?>

    Thanks you guys and sorry for the code mess.

Viewing 7 posts - 1 through 7 (of 7 total)

You must be logged in to reply to this topic.

*May or may not contain any actual "CSS" or "Tricks".