Workshop Internet-Präsenz
Referenz HTML-Tags (HTML 4.01, XHTML 1.0)
- Liste der Tags
- Erläuterung der Dokumenttypdefinitionen (DTD)
- Erläuterung der Tag-Typen
- Erläuterung der Abkürzungen
- Erläuterung zu den Attributen
- Anmerkung
- Nicht mehr unterstützte Tags
Liste der Tags
Tag | DTD | Type | Mögliche Attribute | Innerhalb Tag | Umschließt Tags |
---|---|---|---|---|---|
a | S, T, F | inline | %attrs, charset, type, id, name (bei Ankern), href (bei Verweisen), hreflang, rel, rev, accesskey, shape (rect | circle | poly | default), coords, tabindex, onfocus, onblur, [target] | Inline-Elemente außer <a> | |
abbr | S, T, F | inline | %attrs | ||
acronym | S, T, F | inline | %attrs | ||
address | S, T, F | block | %attrs | ||
applet | T, F | inline | %coreattrs, codebase, archive, code, object, alt, name, width, height, align (%ImgAlign), hspace, vspace | ||
area | S, T, F | empty, hidden | %attrs, shape (rect | circle | poly | default), coords, href, nohref, alt, tabindex, accesskey, onfocus, onblur, [target] | <map> | |
b | S, T, F | inline | %attrs | ||
base | S, T, F | empty, hidden | href, [target] | <head> | |
basefont | T, F | inline, empty, hidden | id, size, color, face | ||
bdo | S, T, F | inline | %coreattrs, %events, lang, xml:lang, dir (ltr | rtl) | ||
big | S, T, F | inline | %attrs | ||
blockquote | S, T, F | block | %attrs, cite | ||
body | S, T, F | block | %attrs, onload, onunload, [background, bgcolor, text, link, vlink, alink] | <html> | Inline- und Blockelemente |
br | S, T, F | inline, empty | %coreattrs, [clear (left | all | right | none)] | ||
button | S, T, F | inline | %attrs, name, value, type (button | submit | reset), disabled, tabindex, accesskey, onfocus, onblur | <form>, <label> | Inline- und Block-Elemente außer <a>, <form>, Formularelemente und <iframe> |
caption | S, T, F | block | %attrs, [align (top | bottom | left | right)] | <table> | |
center | T, F | block | %attrs | ||
cite | S, T, F | inline | %attrs | ||
code | S, T, F | inline | %attrs | ||
col | S, T, F | %attrs, span, width, align (left | center | right | justify | char), char, charoff, valign (top | middle | bottom | baseline) | <colgroup> | ||
colgroup | S, T, F | %attrs, span, width, align (left | center | right | justify | char), char, charoff, valign (top | middle | bottom | baseline) | <table> | <col> | |
dd | S, T, F | block | %attrs | <dl> | |
del | S, T, F | inline | %attrs, cite, datetime | ||
dfn | S, T, F | inline | %attrs | ||
dir | T, F | block | %attrs, compact | <li> | |
div | S, T, F | block | %attrs, [%TextAlign] | ||
dl | S, T, F | block | %attrs, [compact] | <dd>, <dt> | |
dt | S, T, F | inline | %attrs | <dl> | |
em | S, T, F | inline | %attrs | ||
fieldset | S, T, F | block | %attrs | <form> | Feldelemente, <legend> |
font | T, F | inline | %coreattrs, %i18n, size, color, face | ||
form | S, T, F | block | %attrs, action, method (get | post), [name], enctype, onsubmit, onreset, accept, accept-charset, [target] | Inline- und Blockelemente außer <form>, insbesondere <input>, <select>, <textarea>, <label>, <button> | |
frame | F | empty | %coreattrs, longdesc, name, src, frameborder, marginwidth, marginheight, noresize, scrolling | <frameset> | |
frameset | F | %coreattrs, rows, cols, onload, onunload | <html> | <frameset>, <frame>, <noframes> | |
h1 | S, T, F | block | %attrs, [%TextAlign] | ||
h2 | S, T, F | block | %attrs, [%TextAlign] | ||
h3 | S, T, F | block | %attrs, [%TextAlign] | ||
h4 | S, T, F | block | %attrs, [%TextAlign] | ||
h5 | S, T, F | block | %attrs, [%TextAlign] | ||
h6 | S, T, F | block | %attrs, [%TextAlign] | ||
head | S, T, F | hidden | %i18n, profile | <html> | <title>, <base>, <script>, <style>, <meta>, <link>, <object>, <isindex> |
hr | S, T, F | block, empty | %attrs, [align (left | center | right), noshade, size, width] | ||
html | S, T, F | block | %i18n, xmlns | <head>, <body>, <frameset> | |
i | S, T, F | inline | %attrs | ||
iframe | T, F | inline | %coreattrs, longdesc, name, src, frameborder, marginwidth, marginheight, scrolling, align (%ImgAlign), height, width | ||
img | S, T, F | inline, empty | %attrs, src, alt, [name], longdesc, height, width, usemap, ismap, [align (%ImgAlign), border, hspace, vspace] | ||
input | S, T, F | inline, empty | %attrs, type (%InputType), name, value, checked, disabled, readonly, size, maxlength, src, alt, usemap, tabindex, accesskey, onfocus, onblur, onselect, onchange, accept, [align (%ImgAlign)] | <form>, <label> | |
ins | S, T, F | inline | %attrs, cite, datetime | ||
isindex | T, F | block, empty | %coreattrs, %i18n, promt | <head> | |
kbd | S, T, F | inline | %attrs | ||
label | S, T, F | inline | %attrs, for, accesskey, onfocus, onblur | <form> | Formularelement |
legend | S, T, F | inline | %attrs, accesskey, [align (top | bottom | left | right)] | <form>, <fieldset> | |
li | S, T, F | block | %attrs, [type, value] | <ol>, <ul>, <menu>, <dir> | |
link | S, T, F | empty, hidden | %attrs, charset, href, hreflang, type, rel, rev, media, [target] | <head> | |
map | S, T, F | inline | %i18n, %events, id, class, style, title, name | <area> | |
menu | T, F | block | %attrs, compact | <li> | |
meta | S, T, F | empty, hidden | %i18n, http-equiv, name, content, scheme | <head> | |
noframes | F | block | %attrs | <body>, Inline- und Blockelemente | |
noscript | S, T, F | inline, hidden | %attrs | ||
object | S, T, F | inline | %attrs, declare, classid, codebase, data, type, codetype, archive, standby, height, width, usemap, name, tabindex, [align (%ImgAlign), border, hspace, vspace] | <param> | |
ol | S, T, F | block | %attrs, [type (Zahlentyp), compact, start] | <li> | |
optgroup | S, T, F | inline | %attrs, disabled, label | <select> | |
option | S, T, F | inline | %attrs, selected, disabled, label, value | <select> | |
p | S, T, F | block | %attrs, [%TextAlign] | ||
param | S, T, F | empty, hidden | id, name, value, valuetype, type | <object> | |
pre | S, T, F | block | %attrs, [width (Zahl)], xml:space | Inline-Elemente außer <img>, <object>, <applet>, <big>, <small>, <sub>, <sup>, <font>, <basefont> | |
q | S, T, F | inline | %attrs, cite | ||
s | T, F | inline | %attrs | ||
samp | S, T, F | inline | %attrs | ||
script | S, T, F | inline, hidden | charset, type, [language], src, defer, xml:space | <head>, <body>, <frameset> | |
select | S, T, F | inline | %attrs, name, size, multiple, disabled, tabindex, onfocus, onblur, onchange | <form>, <label> | <optgroup>, <option> |
small | S, T, F | inline | %attrs | ||
span | S, T, F | inline | %attrs | ||
strike | T, F | inline | %attrs | ||
strong | S, T, F | inline | %attrs | ||
style | S, T, F | hidden | %i18n, type, media, title, xml:space | <head> | |
sub | S, T, F | inline | %attrs | ||
sup | S, T, F | inline | %attrs | ||
table | S, T, F | block | %attrs, summary, width, border, frame, rules (none | groups | rows | cols | all), cellspacing, cellpadding, [align (left | center | right), bgcolor] | <caption>, <thead>, <tbody>, <tfoot>, <colgroup>, <col>, <tr>, <td>, <th> | |
tbody | S, T, F | %attrs, align (left | center | right | justify | char), char, charoff, valign (top | middle | bottom | baseline) | <table> | <tr> | |
td | S, T, F | table-cell | %attrs, abbr, axis, headers, scope, rowspan, colspan, align (left | center | right | justify | char), char, charoff, valign (top | middle | bottom | baseline), [nowrap, bgcolor, width, height] | <tr> | |
textarea | S, T, F | inline | %attrs, name, rows, cols, disabled, readonly, tabindex, accesskey, onfocus, onblur, onselect, onchange | <form>, <label> | |
tfoot | S, T, F | %attrs, align (left | center | right | justify | char), char, charoff, valign (top | middle | bottom | baseline) | <table> | <tr> | |
th | S, T, F | table-cell | %attrs, abbr, axis, headers, scope, rowspan, colspan, align (left | center | right | justify | char), char, charoff, valign (top | middle | bottom | baseline), [nowrap, bgcolor, width, height] | <tr> | |
thead | S, T, F | %attrs, align (left | center | right | justify | char), char, charoff, valign (top | middle | bottom | baseline) | <table> | <tr> | |
title | S, T, F | hidden | %i18n | <head> | |
tr | S, T, F | %attrs, align (left | center | right | justify | char), char, charoff, valign (top | middle | bottom | baseline), [bgcolor] | <table>, <thead>, <tbody>, <tfoot> | <td>, <th> | |
tt | S, T, F | inline | %attrs | ||
u | T, F | inline | %attrs | ||
ul | S, T, F | block | %attrs, [type (disc | square | circle), compact] | <li> | |
var | S, T, F | inline | %attrs |
Erläuterung der Dokumenttypdefinitionen (DTD)
DTD | Erläuterung |
---|---|
S | XHTML 1.0, Strict Stellt die kleinste Untermenge von HTML-Tags und deren Attributen dar. Nicht definiert sind die Tags <applet>, <basefont>, <center>, <dir>, <font>, <frame>, <frameset>, <iframe>, <isindex>, <menu>, <noframes>, <s>, <strike> und <u>. Die fehlenden Tags bzw. Attribute (Hintergründe, Textausrichtung) können und sollen über Cascading Style Sheets realisiert werden. |
T | XHTML 1.0, Transitional Stellt mit einigen Ergänzungen zur Version XHTML 1.0, Strict, einen Kompromiss insbesondere für die Umstellung früherer HTML-Versionen bzw. zur Unterstützung älterer Browser dar. |
F | XHTML 1.0, Frameset Ergänzung der Version XHTML 1.0, Transitional, um Tags zur Frameset-Definition wie <frameset>, <frame> und <noframes>. |
Erläuterung der Tag-Typen
Tag-Type | Bedeutung |
---|---|
inline | Textlevel-Element, zeichengebundenes Element. |
block | Block-Element, absatzgebundenes Element. |
table-cell | Tabellen-Zelle. |
hidden | Element, das nicht dargestellt wird. |
empty | Element umschließ keinen Text oder kein weiteres Tag, z.B. <hr />, es besitzt daher kein schließendes Tag. |
Erläuterung der Abkürzungen
Erläuterung zu den Attributen
Klammer | Bedeutung |
---|---|
( ) | Liste möglicher Attributwerte. |
[ ] | Attribute, die nur in den Versionen XHTML 1.0, Transitional, und XHTML 1.0, Frameset, definiert sind. |
type | Dieses Attribut ist unbedingt erforderlich. |
type | Dieses Attribut sollte definiert sein. |
Anmerkung
Obige Liste wurde auf der Basis der Dokumenttypdeklarationen XHTML 1.0, Strict, XHTML 1.0, Transitional und XHTML 1.0, Frameset des W3 Konsortiums erstellt.
Nicht mehr unterstützte Tags
Nachfolgende Tags werden nicht mehr unterstützt:
<embed>: ersetzbar durch <object>-Tag,
<nobr>: ersetzbar durch nichtumbrechbaren Leeraum ( ) und
<wbr>: ersetzbar durch Systemtrennstrich (soft hyphen) ­ (­).