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 Foundations The Box Model Width, Height and Overflow Properties

Andrew Thomas
seal-mask
.a{fill-rule:evenodd;}techdegree
Andrew Thomas
Front End Web Development Techdegree Student 14,698 Points

Code Challenge: Box Model

I'm having trouble with this challenge:

"Display the links in the nav as inline block elements."

Here is my code. The a elements in the nav are the only a elements in the html.

HTML:

<nav>
    <a href="#">About Me</a>
    <a href="#">My Work</a>
    <a href="#">Contact Me</a>
</nav>

CSS:

a {
  display: block;
}

Please help?

2 Answers

Andrew Corcoran
Andrew Corcoran
20,552 Points

Hi Andrew,

inline-block is actually a property value all its own similar to block. You can learn more about the possible values of the display property here.

  display: inline-block;
Andrew Thomas
seal-mask
.a{fill-rule:evenodd;}techdegree
Andrew Thomas
Front End Web Development Techdegree Student 14,698 Points

Ahh... problem solved.

The value should be inline-block. I don't remember the video touching on this, and still am not quite sure what inline-block means. Are they not mutually exclusive?