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 Treehouse Club: HTML Publish a Story Body, 1st level headline, and style tags

I'm lost writing this code for the body

Challenge Task 1 of 3

Start by writing an opening and closing body tag below the closing head tag, and above the closing html tag.

I have no idea how to proceed. I wish there were a few examples provided in the lesson

index.html
<!DOCTYPE html>
<html>
<head>
    <meta charset="utf-8">
    <title>Once Upon a Time</title>
    <style>
        h1 {text-align:left; color:green}
    </style>
</head>



</html>

4 Answers

Kevin Faust
Kevin Faust
15,353 Points

Hey Paul,

See this code?

</head>



</html>

Its asking you to insert a opening and closing body tag. It would simply look like this:

</head>

<body>
</body>

</html>

Thanks Kevin, I still have some quick questions. What's a body tag? A tag is like a header? Or is it actual text in the body ? Second, can you help me with an example? Lets say you were a baseball writer and the body explained how the yankees won the game last night. Might it be something like this:

</head> <The Yankees won a dramatic game last night to keep their playoff hopes alive.> </body> </html>

Like that?

Kevin Faust
Kevin Faust
15,353 Points

Hey Paul,

A body tag is generally where we put all the main content of our website inside and so we can separate the main content from the head tag content. So yes this is where the actual text of the website is stored. As you can see in the head tag, that just contains some information about our website but it doesn't provide any visible results. And I cant see your example. I think you might've posted it incorrectly.

HI Kevin, I'll show an example, Perhaps you can tell me if correct:

</head> <body> </body> <The Yankees won an important game yesterday and now have secured a playoff spot.> </html>

Hi Paul Casperson ,

You'll want to start by putting a body tag (both the opening and closing tag) in the space provided.

Remember: your opening tag will have <> and your closing will have </.>.

Hope this helps!

Hi Jim, thanks,

An opening tag is the first few words? And the closing tag is last few words?

Again, using a baseball game as an example for a writer. <The yankees won an important game last night to keep their playoff hopes alive> this is an opening tag?

If they can win their final two games, they make the playoffs.> This is a closing tag? the final words used in the bodY?

HI Jim, I'll show an example, Perhaps you can tell me if correct:

</head> <body> </body> <The Yankees won an important game yesterday and now have secured a playoff spot.> </html>