Skip to content

Instantly share code, notes, and snippets.

@codecademydev
Created March 31, 2020 18:46
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save codecademydev/514a13fd5bf4e27411196c401a1f2022 to your computer and use it in GitHub Desktop.
Save codecademydev/514a13fd5bf4e27411196c401a1f2022 to your computer and use it in GitHub Desktop.
Codecademy export
<!DOCTYPE html>
<html>
<head><title>Html|Cheatsheet</title>
<link href="styles.css" type="text/css" rel="stylesheet">
</head>
<header>
<h1>HTML Tables</h1>
<br>
<table>
<thead>
<tr>
<th>Tag</th>
<th>Example</th>
</tr>
</thead>
<tbody>
<tr>
<td>Table tag</td>
<td>&lt;table&gt;</td>
</tr>
<tr>
<td>Table row tag</td>
<td>&lt;tr&gt;</td>
</tr>
<tr>
<td>Table data tag</td>
<td>&lt;td&gt;</td>
</tr>
<tr>
<td>Table head tag</td>
<td>&lt;thead&gt;</td>
</tr>
<tr>
<td>Table body tag</td>
<td>&lt;tbody&gt;</td>
</tr>
<tr>
<td>Table heading tag</td>
<td>&lt;th&gt;</td>
</tr>
<tr>
<td>Table footer tag</td>
<td>&lt;tfoot&gt;</td>
</tr>
<tr>
<td>Attributes</td>
<td>&lt;rowspan=num or colspan=num&gt;</td>
</tr>
</tbody>
</table>
</header>
<main>
<section class="table">
<h2>Table</h2>
<p>"angular table tag is used with opening and closing tags to create table under this table head,row,data are added"</p>
</section>
<section class="table row">
<h2>Table row tag</h2>
<p>"angular tr tag is used to add row to table before adding table head and data"</p>
</section>
<section class="table data">
<h2>Table data tag</h2>
<p>"angular td tag is used to add data element to cell of row"</p>
</section>
<section class="table head">
<h2>Table head tag</h2>
<p>"angular thead is used to define headings of columns"</p>
</section>
<section>
<h2>Table body tag</h2>
<p>"angular tbody tag is used to define the body of table. it does not include the thead and tfoot tags"</p>
</section>
<section class="table heading">
<h2>Table heading tag</h2>
<p>"angular th tag is used to add heading to row and column it is always enclosed in tr tag"</p>
</section>
<section class="table footer">
<h2>Table footer tag</h2>
<p>"angular tfoot tag is used to summarize content at the end of the table"</p>
</section>
<section class="attributes">
<h2>Rowspan and Colspan attributes</h2>
<p>"angular rowspan or colspan is provided with number to which the rows or cols are to be spanned"</p>
</section>
</main>
</html>
thead{
text-align: left;
color: palevioletred;
background-color: powderblue;
font-weight: bold;
font-size: 25px;
}
table,thead{
width: 90%;
font-family: monospace;
}
td,th{
border: 1px solid black;
}
header,body{
background-color: rgb(226, 174, 226);
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment