Academic English I (AE1) - Spring 2018, Kawamoto
EXERCISES
How to make a simple homepage with a table
Step 2. Adding tables
Let us construct a table with the following data:
Week 1 575
Week 2 678
Week 3 801
Week 4 625
Week 5 821
in our sample homepage. For this, we use the <table> tags
between <body> </body> in the homepage source file.
Filename: scores.html
<html>
<head>
</head>
<body>
<table>
</table>
</body>
</html>
|
|
Let us specify the first row of the table with <tr>, </tr>
and the two data items with <td> </td>:
 |
|
<table>
<tr>
<td>Week 1</td>
<td>575</td>
</tr>
</table>
|
By continuing in this way for each row, we get:
Filename: scores.html
<html>
<head>
</head>
<body>
<table>
<tr>
<td>Week 1</td><td>575</td>
</tr>
<tr>
<td>Week 2</td><td>678</td>
</tr>
.
.
.
</table>
</body>
</html>
|
|
|
|
[ View result ]
|
We can add borders to tables as follows:
Filename: scores_with_border.html
<html>
<head>
</head>
<body>
<table border=3>
.
.
.
</table>
</body>
</html>
|
|
|
|
[ View result ]
|
|