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 CSS: Cascading Style Sheets Use ID Selectors

Can't center the wrapper

I can't center the wrapper! I inserted a div element with a unique id named 'unique' and it's still the same as it was before. This is my code:

<div id="unique">
       <section>
          <ul>
            <li>
                <a href="img/numbers-01.jpg">
                <img src="img/numbers-01.jpg" alt="">
                <p>This is the first caption.</p>
                </a>
            </li>
            <li>
                <a href="img/numbers-02.jpg">
                <img src="img/numbers-02.jpg" alt="">
                <p>This is the second caption.</p>
                </a>
            </li>
            <li>
                <a href="img/numbers-06.jpg">
                <img src="img/numbers-06.jpg" alt="">
                <p>This is the third caption.</p>
              </a>
            </li>
            <li>
                <a href="img/numbers-09.jpg">
                <img src="img/numbers-09.jpg" alt="">
                <p>This is the fourth caption.</p>
              </a>
            </li>
            <li>
                <a href="img/numbers-12.jpg">
                <img src="img/numbers-12.jpg" alt="">
                <p>This is the fifth caption.</p>
              </a>
            </li>
          </ul>
        </section>
      <footer>
        <a href="http://facebook.com/goran.penov"><img src="img/facebook-wrap.png" alt="Facebook Logo"></a>
        <a href="http://twitter.com/xposedinthedark"><img src="img/twitter-wrap.png" alt="Twitter Logo"></a>
        <p>&copy; 2016 Goran Penov.</p>
      </footer>
      </div>
      </body>
</html>

2 Answers

Hi Goran,

It would be best if you add your css rules here. So we'll able to help you better.

Cheers!

a {
  text-decoration:none;
}

#unique {
  max-width: 940px;
  margin:0;
}

I forgot 'auto' after zero. Looks like I had zero concentration :) Tnx in advice.