HTML_Quick_Reference_Guide_Renamed
HTML_Quick_Reference_Guide_Renamed
Basic Structure
<!DOCTYPE html>: Defines the document type and version of HTML
<html>: Root element of the HTML document
<head>: Container for metadata (not displayed)
<title>: Sets the title in the browser tab
<body>: Contains the visible page content
Text Formatting
<h1>-<h6>: Headings (h1 is largest, h6 smallest)
<p>: Paragraph
<br>: Line break
<hr>: Horizontal rule (divider)
<b>: Bold text
<strong>: Important (bold) text
<i>: Italic text (visual only)
<cite>: Italic for citing creative work (semantic)
<em>: Emphasized (italic) text
<mark>: Highlighted text
<small>: Smaller text
<del>: Deleted/strikethrough (semantic: removed content)
<s>: Strikethrough (semantic: no longer accurate/relevant)
<ins>: Inserted/underlined text
<sub>: Subscript text
<sup>: Superscript text
Lists
<ul>: Unordered list (bullets)
<ol>: Ordered list (numbers)
<li>: List item
<dl>: Description list
<dt>: Term in a description list
<dd>: Description of the term
Tables
<table>: Defines a table
<tr>: Table row
<td>: Table data/cell
<th>: Table header
<thead>: Groups table head content
<tbody>: Groups body content
<tfoot>: Groups footer content
<caption>: Table title
<col>: Defines column properties
<colgroup>: Groups columns for styling
Semantic Tags
<figure>: Groups media and caption
<figcaption>: Caption for <figure>
<time>: Represents time/date
<address>: Contact information
<code>: Inline code
<pre>: Preformatted text
<kbd>: Keyboard input
<samp>: Sample output
<var>: Variable name
<cite>: Cites a creative work (e.g., book, article, film)
Embedded/Interactive
<iframe>: Embeds another page
<embed>: Embeds external content (e.g., PDF)
<object>: Embeds objects (e.g., Flash)
<canvas>: Drawing via JavaScript
<svg>: Vector graphics
Deprecated/Obsolete Tags
<font>: Font styling (now use CSS)
<center>: Centering content
<marquee>: Scrolling text
<u>: Underlined text (use <ins>)