Created
September 16, 2020 08:28
-
-
Save gougherk/004fc3053382ef8ad6dc18b6f8d59704 to your computer and use it in GitHub Desktop.
Cheatsheet Exercise Codecademy
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!DOCTYPE html> | |
<html lang="en"> | |
<head> | |
<meta charset="UTF-8" /> | |
<meta name="viewport" content="width=device-width, initial-scale=1.0" /> | |
<title>Html table reference</title> | |
<link rel="stylesheet" href="styles.css" /> | |
</head> | |
<body> | |
<h1>HTML Table Reference</h1> | |
<h2>Table Tags</h2> | |
<table border=1 class="center" > | |
<thead> | |
<tr> | |
<th>Tag</th> | |
<th>Name</th> | |
<th colspan="8">Description</th> | |
</tr> | |
</thead> | |
<tbody> | |
<tr> | |
<td><span class="code"><table></span></td> | |
<td>Table</td> | |
<td>The wrapper element for all HTML Tables.</td> | |
</tr> | |
<tr> | |
<td><span class="code"><thead></span></td> | |
<td>Table Head</td> | |
<td>The set of rows defining the column headers in a table.</td> | |
</tr> | |
<tr> | |
<td><span class="code"><tbody></span></td> | |
<td>Table Body</td> | |
<td>The The set of rows containing actual table data.</td> | |
</tr> | |
<tr> | |
<td><span class="code"><tr></span></td> | |
<td>Table Row</td> | |
<td>The table row container.</td> | |
</tr> | |
<tr> | |
<td><span class="code"><td></span></td> | |
<td>Table Data</td> | |
<td>The table data container.</td> | |
</tr> | |
<tr> | |
<td><span class="code"><tfoot></span></td> | |
<td>Table Foot</td> | |
<td>The set of rows defining the footer in a table.</td> | |
</tr> | |
</tbody> | |
</table> | |
<br> | |
<h2>Table Attributes</h2> | |
<tfoot> | |
<table border=1 class="center" > | |
<thead> | |
<tr> | |
<th>Attribute</th> | |
<th>Name</th> | |
<th colspan="8">Description</th> | |
</tr> | |
</thead> | |
<tr> | |
<td><span class="code">colspan</span></td> | |
<td>Column Span</td> | |
<td>Defines how many columns a td element should span.</td> | |
</tr> | |
<tr> | |
<td><span class="code">rowspan</span></td></td> | |
<td>Row Span</td> | |
<td>Defines how many rows a td element should span.</td> | |
</tr> | |
</table> | |
</tfoot> | |
</tbody> | |
</body> | |
</html> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
h1 { | |
text-align: center; | |
text-decoration-style: bold; | |
} | |
h2 { | |
text-align: center; | |
color: blueviolet; | |
text-decoration-style: bold; | |
} | |
th { | |
background-color: rgb(228, 154, 228); | |
} | |
.center { | |
margin-left: auto; | |
margin-right: auto; | |
} | |
body { | |
background-color: rgb(206, 204, 204); | |
} | |
table { | |
width: 650px; | |
border: 2px solid darkorchid; | |
margin: 0 auto; | |
} | |
.code { | |
font-family: monospace; | |
background-color: beige; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment