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 HTML First Use HTML Elements

Maya Liberman
seal-mask
.a{fill-rule:evenodd;}techdegree seal-36
Maya Liberman
Full Stack JavaScript Techdegree Graduate 26,360 Points

What is a header element needs to be between body?

I did what was in the video and still it is not correct....

index.html
<!DOCTYPE html>
<html>
  <head>
  <meta charset="utf-8">
    <title> Nick Petite | Designer </title>
  </head>
    <body>
    <h1> Nick Pettite </h1>
  </body>
  <footer> 
  </footer>
</html>

2 Answers

Jason Anders
MOD
Jason Anders
Treehouse Moderator 145,858 Points

A header element is not really a new element, it is just the "header" of a new section. So the challenge just wants you to put a "header," a "section", and a "footer" in the body. Right now, your "footer" is outside the body tags, so you would need to move that up to inside the body, and you are missing the header tags and the section tags (also to be place inside the body).

<!DOCTYPE html>
<html>
  <head>
  <meta charset="utf-8">
    <title> Nick Petite | Designer </title>
  </head>
    <body>
    <h1> Nick Pettite </h1>
      <header></header>
      <section></section>
      <footer> </footer>
  </body>
</html>

I hope this makes sense and helps. Keep coding!

Jason :)

victor ollervidez
victor ollervidez
14,934 Points

Hi Maya the final step is to add a "header", "section", and "footer" element. The "header" goes right below the body tag think of it as where you would place the navigation or "header" of your page try not to confuse it with the "head" tag. Also the "footer" element goes right before the ending body tag not after. I have fixed your code below. :D hope it helps

<!DOCTYPE html>
<html>
<head>
  <meta charset="utf-8">
  <title>Hello</title>
</head>
<body>
<header>

</header>

<section>

</section>  

 <footer> 
</footer>
</body>
</html>