Você está na página 1de 2

EET

H
S
Page 1 of 2
AT
E
H
C
L
M
T
H

learntoprogram .tv

Cheat Sheet
Basic HTML Document Outline:

Document Structure

<html>

<head>
<title>HTML Doc</title>

</head>

<body>

<div>
<h1>HTML Document</h1>
<p>This is an HTML document!</p>

</div>

</body>
</html>

<a href="url">

Hyperlink to another location.

<h1>,<h2>,<h3>,
<h4>,<h5>,<h6>

Set text as heading, determine size.

<div>

Define a division or section of an HTML


document, used to group block-elements for
formatting with CSS.

<span>

Group inline elements, used to add a hook to


text. No formatting by itself.

<p>

Define a paragraph.

HTML Document Outline

<br>

Define a line break.

<hr>

Define a horizontal rule or thematic break.

<html>

HTML document.

<head>

Document header information.

<body>

Document body.

Page Information

Lists
<ol>

Define an ordered list, or a list that is ordered


numerically or alphabetically.

<ul>

Define an unordered list.

<li>

Define an item on an ordered or unordered


list.

<meta>

Metadata about the document. Will not be


visible, but is machine parsable.

<title>

Define the title of the document, and is


required.

<dl>

<link>

Define a link between the HTML and an


external resource, usually a stylesheet.

Define a description list, used with <dt> and


<dd>

<dt>

<style>

Define style information.

Define a description term, or the name of an


item in a description list.

<script>

Define a client-side script.

<dd>

Define a description of an item in a


description list.

EET
H
S
Page 2 of 2
AT
E
H
C
L
M
T
H
Forms
<form>

Create a form that receives user input.

<fieldset>

Group related form elements together.

<label>

Define the label for an <input> form element.

<input>

Define a field where a user can enter data.

<select>

Create a drop-down list in a form.

<optgroup>

Group related options in a drop-down list.

<option>

Define an option in a drop-down list.

<textarea>

Create a text input field within a form.

<button>

Create a clickable button.

Tables
<table>

Define an HTML table consisting of one or


more <tr>, <th>, and <td> elements.

<caption>

A table caption.

<thead>

Define table header content. Must be used


after <table>, <caption>, and <colgroup> but
before <tbody>, <tfoot>, and <tr>.

<tbody>

Define the body of a table. Must be used after


<table>, <caption>, <colgroup>, or <thead>
elements.

<colgroup>

Group columns together for formatting.

<col>

Specify properties for individual columns


within a <colgroup>

learntoprogram .tv

<tr>

Define a row in an HTML table.

<th>

Define a cell in a table row as a header


element.

<td>

Define a cell in a table row as a data element.

Text Formatting
<strong>

Define important text.

<em>

Define emphasized text.

<blockquote>

Define text quoted from another source.

<q>

Define a short quotation.

<abbr>

Define an abbreviation.

<address>

Define the contact information for the author


of a document or article.

<pre>

Define pre-formatted, text that preserves


spaces and line-breaks.

<dfn>

Set the defining instance of a term.

<code>

Define a piece of computer code.

<cite>

Define a citation of the title of a work.

<sub>

Define subscript text.

<sup>

Define superscript text.

<bdo>

Set bi-directional override, making text


direction reverse.

Você também pode gostar