Welcome to the Treehouse Community

The Treehouse Community is a meeting place for developers, designers, and programmers of all backgrounds and skill levels to get support. Collaborate here on code errors or bugs that you need feedback on, or asking for an extra set of eyes on your latest project. Join thousands of Treehouse students and alumni in the community today. (Note: Only Treehouse students can comment or ask questions, but non-students are welcome to browse our conversations.)

Looking to learn something new?

Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and a supportive community. Start your free trial today.

HTML HTML Tables HTML Tables

Miriam Allman
PLUS
Miriam Allman
Courses Plus Student 1,761 Points

Put two header cells with any text inside of the row

Put two header cells with any text inside of the row Here is the code - what is wrong with this?

<!doctype html>
<html lang="en">
<head>
     <meta charset="ut-8">
     <title>My Page</title>
</head>

<body>
   <table  border="5"  cellpadding="5"  cellspacing="5">  
       <thead>
       <tr>
           <td>Oranges</td>
           <th>These Are <br>My Favorite Fruits</th>
           <th valign="middle">Vegetables </th>
       </tr>

   </thead>
   <tfoot>
       <tr>
           <td  colspan="2"  align="center"> Thanks for reading!</td>
    </tr>      
   </tfoot>
    <tr>
      <td>Oranges</td>
      <td>Carrots</td>
    </tr>
    <tr>
      <td>Apples</td>
      <td>Broccoli</td>
  </tr>
  <tr>
      <td>Strawberries</td>
      <td>Asparagus</td>
  </tr>
    <tr>
        <td></td>
        <td>Potatoes</td>
   </table> 
</body>
</html>

1 Answer

Steven Parker
Steven Parker
221,070 Points

The instructions say "Put two header cells with any text inside of the row..." but the code shown here has two header cells and a data cell in that row.

You also seem to have several elements that the instructions have not asked for (yet). For best results, always do each task of a challenge in order, and only do what is asked for and nothing extra.