Welcome to the Treehouse Community

Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.

Looking to learn something new?

Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.

Start your free trial

CSS

CSS won't float left

Here's some of my css

/***********************
PAGE: ABOUT (MAIN CSS)
************************/

.profile-photo {
  display: block;
  max-width: 150px;
  margin: 0 auto 30px;
  border-radius: 35px;
}
 /***********************
    PAGE: ABOUT (RESPONSIVE)
 ************************/  

.profile-photo {
  float: left;
  margin: 0 5% 80px 0;  
}

and here's my corresponding html

<div id="wrapper">
     <section>
       <img src="img/photo-1.JPG" alt="Photograph of Scott Kaplan and friends" class="profile-photo">
       <h3>About</h3>
       <p>Hi, I'm Scott Kaplan &#40;that's me in the middle&#41;. This is my portfolio where I share my work.</p>
       <p>I'm a content writer looking to learn more about web design and web applications. When I'm not writing or butchering code, you can find me curled up in a coffee shop with a good book, running around Rock Creek Park, or drinking good beer with friends.</p>
      <p>If you're interested, check me out on Twitter <a href="http://twitter.com/aqscott">@aqscott</a>.</p>

3 Answers

Maybe you have to close your div element?

Nope, that's closed further down in the code.

<div id="wrapper">
     <section>
      <ul id="gallery">
       <li>
        <a href="img/numbers-01.jpg">
          <img src="img/numbers-01.jpg" alt="">
          <p>Experimentation with color and texture.</p> 
        </a> 
       </li>
       <li>
        <a href="img/numbers-02.jpg">
          <img src="img/numbers-02.jpg" alt="">
          <p>Playing with blending modes in photoshop.</p> 
        </a> 
       </li>
       <li>
        <a href="img/numbers-06.jpg">
          <img src="img/numbers-06.jpg" alt="">
          <p>Trying to create an 80's style of glows.</p> 
        </a> 
       </li>
        <li>
        <a href="img/numbers-09.jpg">
          <img src="img/numbers-09.jpg" alt="">
          <p>Drips created using Photoshop brushes.</p> 
        </a> 
       </li>
        <li>
        <a href="img/numbers-12.jpg">
          <img src="img/numbers-12.jpg" alt="">
          <p>Creating shapes using repetition.</p> 
        </a> 
       </li> 
      </ul>
     </section>
     <footer>
       <a href="http://twitter.com/aqscott"><img src="img/twitter-wrap.png" alt="Twitter Logo" class="social icon"></a>
       <a href="http://facebook.com/totesmgotes"><img src="img/facebook-wrap.png" alt="Facebook Logo" class="social icon"></a>
      <p>&copy; 2014 Scott Kaplan.</p>
     </footer>
   </div>  

Scott,

I think you pasted the wrong html, from your index page. The page you initially referenced was from the about page. Would you mind pasting the complete portion from the about page?

Maybe try to paste this clearfix hack into your css:

http://nicolasgallagher.com/micro-clearfix-hack/