Creating a Table with Headers in HTML
📖 Scenario: You are building a simple webpage to show a list of fruits and their colors in a table. To make the table clear, you want to add headers that describe each column.
🎯 Goal: Create an HTML table with two columns: one for the fruit name and one for its color. Add proper table headers to label these columns.
📋 What You'll Learn
Use semantic HTML table elements
Add a header row with two headers: 'Fruit' and 'Color'
Include at least three rows of fruit data
Ensure the table is accessible and structured correctly
💡 Why This Matters
🌍 Real World
Tables are used everywhere on websites to show data clearly, like product lists, schedules, or contact info. Using headers and semantic tags helps everyone understand the data.
💼 Career
Knowing how to build accessible and well-structured tables is important for web developers, especially when working on dashboards, reports, or any data-heavy websites.
Progress0 / 4 steps