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

My Nav bar keeps going above my header

I have nothing else on the page except for a header and within in it is

header h1> some text h1> nav> ul> li> 1 </li> li> 2 </li> li> 3 </li> ul> nav>

header (wrote it like that because it worn show up on the forum as code)

CSS

h1 { font-family: 'VT323', sans-serif ; text-align: center; width: 16em; position: absolute;

}

nav {

text-align: center; }

nav ul { list-style: none; margin: 0 10px; padding: 0; display:inline-block;

}

I cant figure out the problem? Isnt h1 a block element? so automatically it goes with the flow of the document? Why is the nav bar going on top of the h1?

maybe try to delete the block element

2 Answers

maybe try deleting the block element

thank you

your welcome hope it works