HTML and CSS Reference
In-Depth Information
the time of the first activity of the day, “8:30 AM” in this case. We'll also include a
datetime attribute on the <time> element with a value noting the time in
hours, minutes, and seconds, 08:30:00 .
In the <td> element that follows the <th> element we'll include the activity
name (since there aren't any speakers at this time), which is “Registration” in this
case. Since there is only one activity at this time we'll also include the colspan
attribute with a value of 2 on the <td> element.
In all, the code for our first table looks like this:
Click here to view code image
1. <table>
2. <thead>
3. <tr>
4. <th scope="row">
5. Workshops
6. </th>
7. <td colspan="2">
8. August 24th
9. </td>
10. </tr>
11. </thead>
12. <tbody>
13. <tr>
14. <th scope="row">
15. <time datetime="08:30:00">8:30 AM</time>
16. </th>
17. <td colspan="2">
18. Registration
19. </td>
20. </tr>
21. </tbody>
22. </table>
6. For the second row within the <tbody> element let's add a <tr> element just
below our previous row. Then let's add a <th> element with the scope attribute
with a value of row , and again add a <time> element with the appropriate time
and datetime attribute value within that <th> element.
After the <th> element let's add two <td> elements for the two speakers present-
ing at that time. Directly inside each <td> element we'll add an <a> element,
which will link back to where that speaker is positioned on the Speakers page. Re-
member, we added id attributes with each speaker's name to the parent elements
for each speaker. Using that id attribute value preceded by the speakers.html
Search WWH ::




Custom Search