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

HTML How to Make a Website Responsive Web Design and Testing Adjust the Profile Page and Header

Paula Mourad
Paula Mourad
5,154 Points

"About" page not becoming 2 columns layout

Hi!

My "about" page does not become a 2 columns layout.

My CSS:

@media screen and (min-width: 480px) { /* TWO COLUMN LAYOUT */

#primary {
  width: 50%;
  float: left;
}

#secondary {
  width: 40%;
  float: right;
}


/* PAGE: PORTFOLIO */

#gallery li {
  width: 28.3333%;
} 

#gallery li:nth-child(4n) {
  clear: left;
}

/* PAGE: ABOUT */

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

} }

4 Answers

Matt Milburn
Matt Milburn
20,786 Points

Hi Paula,

Can you send your HTML as well?

Paula Mourad
Paula Mourad
5,154 Points

Hi Matt, Sure, here it is!

<!DOCTYPE html>
<html>
  <head>
    <meta charset="utf-8">
    <title>Paula Mourad | Designer</title>
    <link rel="stylesheet" href="css/normalize.css">
    <link href="https://fonts.googleapis.com/css?family=Changa+One|Open+Sans:400,400i,700,700i,800" rel="stylesheet">
    <link rel="stylesheet" href="css/main.css">
    <link rel="stylesheet" href="css/responsive.css">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
  </head>
  <body>
    <header>
      <a href="index.html" alt="" id="logo">
        <h1>Paula Mourad</h1>
        <h2>Designer</h2>
      </a>
      <nav>
        <ul>
          <li><a href="index.html">Portfolio</a></li>
          <li><a href="about.html" class="selected">About</a></li>
          <li><a href="contact.html">Contact</a></li>
        </ul>
      </nav>
    </header>
      <div id="wrapper">
      <section>
        <img src="img/nick.jpg" alt="Photograph of Nick Pettit" class="profile-photo">
        <h3>About</h3>
        <p>Hi! I'm Paula Mourad and this is my portfolio. I'm a new student here at TechDegree and I am taking this course because I want to learn Front-End programing, so that I can get a better job beign a designer. In the future, I would like to go to the USA and study Musical Theatre as a career and make a living out of it!</p>
        <p>If you would like to follow me on twitter, my username is <a href="http://www.twitter.com">@pmourad84</a>.</p>
      </section>
      <footer>
        <a href="http://www.twitter.com"><img src="img/twitter-wrap.png" alt="Twitter Logo" class="social-icon"></a>
        <a href="http://www.facebook.com"><img src="img/facebook-wrap.png" alt="Facebook Logo" class="social-icon"></a>
        <p>&copy; 2016 Paula Mourad.</p>
      </footer>
    </div>
  </body>
</html>
```html
Matt Milburn
Matt Milburn
20,786 Points

I can say your HTML looks free of errors. However, I can't see enough of the CSS to truly understand what is preventing a 2 column layout for you. Could I ask you to post more (if not all) of your CSS as well?

Or better yet, do you happen to have a live link where we could see this?

Paula Mourad
Paula Mourad
5,154 Points

Hey Matt, Thanks for all your help.

These are my links: http://port-80-ns1tqib7jk.treehouse-app.com/index.html http://port-80-ns1tqib7jk.treehouse-app.com/about.html http://port-80-ns1tqib7jk.treehouse-app.com/contact.html

Let me know if you have any trouble viewing these links. Thanks once again! Paula

Belve Marks
Belve Marks
7,332 Points

Hey Paula!

Unfortunately, I couldn't follow those links. But...

I'm not seeing any id of "primary or "secondary". The only style implemented in the CSS here seems to be the class "profile-photo", which is floated left. The following text is behaving accordingly. Add those in appropriately should get you on the right road.

Hope this helps!

'''this is only a test <!DOCTYPE html> <html> <head> <meta charset="utf-8"> <title>John Schaub | Designer</title> <link rel="stylesheet" href="css/normalize.css"> <link href="https://fonts.googleapis.com/css?family=Changa+One|Open+Sans" rel="stylesheet"> <link rel="stylesheet" href="css/main.css"> <link rel="stylesheet" href="css/responsive.css">'''