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 HTML Tables HTML Tables

Why can't I pass the table challenge?

this is my code...

<table> <thead> <tbody> <tr> <th>head 1</th> <th>head2</th> </tr> </tbody> </thead> </table>

it tells me to add a table body. what am I doing wrong?

7 Answers

Seven B.
Seven B.
5,906 Points

Hi Christina, I can't actually see your code, but if I understand what you're asking it's about the table body part of the Quiz. It sounds like you haven't done anything wrong yet.

You have finished closed the table head and now it is asking for the table body. The thead groups the table header content together. The tbody groups the table body content together.

    <title>HTML Tables Challenge</title>
    <h1>HTML Tables Challenge</h1>

    <!-- Write your code below -->
            <th>head 1</th>
            <th>head 2</th>

Here's a link that explains more: http://www.w3schools.com/tags/tag_tbody.asp

Hope that helps!
Seven B.
Seven B.
5,906 Points

I just went through the quiz and didn't have a problem with it. There could be a glitch, but I have never experienced one in the program, usually when I do it's related to something I'm missing. However, that doesn't mean there isn't a glitch. Post your code here and then we can provide you with feedback.

If you're not sure how to paste your code here, click on the Markdown Cheatsheet link in gray right underneath the text box and above the Post Answer button.

There are hints for how to paste your code.

Hi Christina, If you could copy and past a larger section of your code I am sure we would be able to help.

oh sorry I don't know why it didn't paste!

let's try again..

it asks me to add the table body tag. <table> <thead> <tbody> <tr></tr> <tr> <th>head 1</th> <th>head 2</th> </tr> <tbody> </thead> </table> </body> </html>

ugh how do I copy and paste my code into here? it doesn't seem to want to work!

Thanks! yes that is what I did! Is there sometimes a glitch in the program? I can't seem to pass this level and it's driving me nuts!

oh I see what I did wrong...I put the <tbody> in the wrong position, wrapping the <thead>. What is the point of the <thead> if you can't even see it in the table? I don't see anything within <thead>