Wilbur - HTML 3.2Wilbur - HTML 3.2
For the latest version of this overview, please refer to the WDG's Wilbur
reference at
Attributes:SRC=URL, ALT=string, ALIGN=left|right|top|middle|bottom,
HEIGHT=n, WIDTH=n, BORDER=n, HSPACE=n, VSPACE=n, USEMAP=URL, ISMAP
Contents:None (Empty).
May occur in:BODY, H1, H2, H3, H4, H5, H6, P, LI, DT, DD, DIV, CENTER,
BLOCKQUOTE, FORM, TD, TH, PRE, ADDRESS as well as TT, I, B, U, STRIKE,
BIG, SMALL, SUP, SUB, EM, STRONG, DFN, CODE, SAMP, KBD, VAR, CITE, A, IMG,
FONT, APPLET, BR, SCRIPT, MAP, BASEFONT, INPUT, SELECT, TEXTAREA and plain
text.
The first section, Appearance, gives a common way to use this tag. As you can
see here, the IMG tag does not have an ending tag. If the beginning or ending
tag appears inside square brackets, it is optional and may be left off.
The next section describes the attributes for the IMG tag. If an attribute
appears in bold, it is required, otherwise it may be omitted. In the above case,
SRC is required, but the other attributes are not. Note that the attributes
themselves are listed in all caps, and the possible values (if possible) in
lower case. Note that an attribute value must be quoted if it contains more than
just letters, digits, hyphens and periods.
The contents section describes which tags are permitted inside this tag. For
IMG, there are none. And last, you can see which tags allow IMG inside them.
The attributes and their values are noted in a very compact format as well. The
"|" character is used to separate mutually exclusive attributes or values. For
example, A=foo|bar indicates that attribute "A" may get foo or bar as value, but
not both, or anything else. A=string|B=string indicates that you may use either
A or B, but not both.
If an attribute can take more possible values than can be given in a list, the
following special symbols are used:
n
A number. It must be an integer, and not have a "-" or "+" sign prepended.
Numbers do not have to be enclosed in quotes.
p%
A percentage. The percentage must also be an integer. Exactly what the
percentage applies to depends on the tag. Percentages must be enclosed in
quotes.
URL
An URL. This can be an absolute or a relative URL, depending on the situation.
In most cases, both are permitted. It is recommended that URLs always be
enclosed in quotes.
string
A string of characters. Any character is permitted, including entities. It is
recommended that strings are always enclosed in quotes.
#RRGGBB
A color code, in hexadecimal notation. The color is constructed in the
red-green-blue format. Each part gets a hexadecimal number between 00 and FF,
and it should be given in two digits at all times. Note that a color code must
have a # as the first character, and it must be enclosed in quotes.
ADDRESS - Address information
Appearance:
Attributes:None. Contents:H1, H2, H3, H4, H5, H6, P, UL, OL, DIR, MENU, PRE, DL, DIV, CENTER, BLOCKQUOTE, FORM, HR, TABLE, ADDRESS as well as TT, I, B, U, STRIKE, BIG, SMALL, SUB, SUP, EM, STRONG, DFN, CODE, SAMP, KBD, VAR, CITE, A, APPLET, IMG, FONT, BASEFONT, BR, MAP, INPUT, SELECT, TEXTAREA and plain text. May occur in:BODY, DIV, CENTER, BLOCKQUOTE, FORM, TH, TD and DD, LI. If you are quoting more than a few lines from a document, use a BLOCKQUOTE to indicate this. Block quotations are often rendered with indented margins, and possibly in italics, although a rendering with the standard quotation symbol for E-mail, "> ", is of course also possible. Notes: If you quote from someone else's work, don't forget to include a credit and/or copyright notice. Do not use BLOCKQUOTE simply to create indented text. This is not the required rendering, so you will not achieve the effect you want on all browsers. It will also confuse page indexers and summarizers. BODY - Document body Appearance:[] [] Attributes:BACKGROUND=URL, BGCOLOR=#RRGGBB, TEXT=#RRGGBB, LINK=#RRGGBB, VLINK=#RRGGBB, ALINK=#RRGGBB Contents:H1, H2, H3, H4, H5, H6, P, UL, OL, DIR, MENU, PRE, DL, DIV, CENTER, BLOCKQUOTE, FORM, HR, TABLE, ADDRESS as well as TT, I, B, U, STRIKE, BIG, SMALL, SUB, SUP, EM, STRONG, DFN, CODE, SAMP, KBD, VAR, CITE, A, APPLET, IMG, FONT, BASEFONT, BR, MAP, INPUT, SELECT, TEXTAREA and plain text. May occur in:HTML. The BODY tag contains the actual contents of the document. That contents should consist of block elements only. You may put in plain text in the body, this is then assumed to be inside a P container. The attributes contain the appearance of the document. The BACKGROUND attribute should point to the location of an image, which is used as the (tiled) background of the document. The other attributes set the colors for the background, text, links, visited links and active (currently being selected) links, using the order above. The color is composed by specifying the red, green and blue components of the color in hexadecimal notation, with a # in front. For example, to specify white, the red, green and blue components are 255, 255, 255, so you would use "#FFFFFF". You can also use the following color names, although they are not as widely supported as the codes: Black: #000000 Green: #008000 Silver: #C0C0C0 Lime: #00FF00 Gray: #808080 Olive: #808000 White: #FFFFFF Yellow: #FFFF00 Maroon: #800000 Navy: #000080 Red: #FF0000 Blue: #0000FF Purple: #800080 Teal: #008080 Fuchsia: #FF00FF Aqua: #00FFFF The BODY tag is optional; if you put all the HEAD elements first, the browser can immediately see where the actual document body begins. Notes: If the background image cannot be displayed, the color specified in BGCOLOR will be used. If you set one of the attributes, set them all. Otherwise your specified color may conflict with a user's default. This could result in unreadable text. For example, imagine that you set your TEXT color to light gray, but forget to set the background. Then someone with a light gray background will not see anything at all. Do not set unvisited and visited links to the same color, it will confuse your readers. The names that you can use instead of the hexadecimal values are not as widely supported as the color codes. Netscape 1.1 produced a "fade" effect when more than one BODY tag was used in a document. It would render the BGCOLOR colors in sequence. This bug has been fixed in later versions. Do not expect that using multiple BODY tags will give the intended results. BR - Forced line break Appearance:
Attributes:None.
Contents:TT, I, B, U, STRIKE, BIG, SMALL, SUB, SUP, EM, STRONG, DFN, CODE,
SAMP, KBD, VAR, CITE, A, APPLET, IMG, FONT, BASEFONT, BR, MAP, INPUT,
SELECT, TEXTAREA and plain text.
May occur in:BODY, DIV, CENTER, BLOCKQUOTE, FORM, TH, TD, DT, DD, LI, P,
H1, H2, H3, H4, H5, H6, PRE, ADDRESS, TT, I, B, U, STRIKE, BIG, SMALL,
SUB, SUP, EM, STRONG, DFN, CODE, SAMP, KBD, VAR, CITE, FONT, A, APPLET,
CAPTION.
CODE is used for snippets of code which appear inside a paragraph of text. It is
usually rendered in a monospaced font. You can use this tag to mark up things
like for ( ; ; ) ; is a nice way to make an endless loop in C.
For larger blocks of code, use PRE instead. If what you are marking up is what a
user should type in, use KBD.
Notes:
CODE will usually be rendered in a monospaced font, but multiple spaces are
collapsed, unlike in PRE. This can screw up the spacing in your code if you
want to provide more than one line.
DD - Definition
Appearance:
if the image was on the same page.
Notes:
Client-side imagemaps are not widely supported yet, so try to offer a textual
alternative or also use a server-side imagemap. This can be done by putting
the IMG tag with the USEMAP attribute inside an A and by adding the ISMAP
attribute.
Having the imagemap data in a separate file is not as widely supported as
inlined data.
MENU - Menu item list
Appearance:
Attributes:COMPACT
Contents:LI.
May occur in:BODY, DIV, CENTER, BLOCKQUOTE, FORM, TH, TD and DD, LI.
The MENU item produces a list like UL, but it should be rendered more compact.
Not all browsers make this distinction, and some render it without a bullet at
all.
Notes:
It is not permitted to use a block element, list element or TABLE in a LI
inside a MENU or DIR.
META - Meta-information
Appearance:
Attributes:HTTP-EQUIV=string|NAME=string, CONTENT=string
Contents:None (Empty).
May occur in:HEAD.
The META tag is used to convey meta-information about the document, but can also
be used to specify headers for the document. You can use either HTTP-EQUIV or
NAME to name the meta-information, but CONTENT must be used in both cases. By
using HTTP-EQUIV, a server should use the name indicated as a header, with the
specified CONTENT as its value. For example,
The server should include the following response headers when the document is
requested:
Expires: Tue, 04 Dec 1993 21:29:02 GMT
Keywords: Nanotechnology, Biochemistry
Reply-to: dsr@w3.org (Dave Raggett)
Popular uses for META include:
This indicates the program used to generate this document. It is often the
name of the HTML editor used.
This indicates the name of the author.
Provides keywords for search engines such as Infoseek or Alta Vista. These are
added to the keywords found in the document itself. If you insert a keyword
more than seven times here, the whole tag will be ignored!
Search engines which support the above tag will now display the text you
specify here, rather than the first few lines of text from the actual document
when the document shows up in a search result. You have about 1,000 characters
for your description, but not all these will be used.
This is a so-called "meta refresh", which on certain browsers causes the
document mentioned in the URL to be loaded after n seconds. This can be used
for slide shows or for often-changing information, but has some drawbacks. In
particular, if you use a value of zero seconds, the user can no longer go
"Back" with his back button. He will be transferred to the specified URL, and
when he presses "back" there, he will go back to the document with the
refresh, which immediately redirects him to the document he tried to get away
from.
This indicates that the document containing this META tag will expire at this
date. If the document is requested after this date, the browser should load a
new copy from the server, instead of using the copy in its cache.
Notes:
Not all servers use the information from META tags to generate headers,
although some browsers will treat what they find in here like it was a header.
The "keywords" and "description" values are currently only used by Alta Vista
and Infoseek.
OL - Ordered list
Appearance:Attributes:WIDTH=n Contents:TT, I, B, U, STRIKE, BIG, SMALL, SUB, SUP, EM, STRONG, DFN, CODE, SAMP, KBD, VAR, CITE, A, APPLET, IMG, FONT, BASEFONT, BR, MAP, INPUT, SELECT, TEXTAREA and plain text. May occur in:BODY, DIV, CENTER, BLOCKQUOTE, FORM, TH, TD and DD, LI. PRE is used to include sections of text in which formatting is critical. Unlike in the other HTML containers, text in a PRE pair will only be wrapped at the linebreaks in the source, and spaces will not be collapsed. You can even use tabs, although it is better to use multiple spaces since those will always be the right number. Text inside this tag will be displayed in a monospaced font to retain the formatting. This is the reason you cannot include font-changing tags inside PRE text. Images are excluded because they can introduce problems with alignment. An image can't be translated to a certain number of characters. The optional WIDTH attribute can be used to indicate how wide the text is (for example, WIDTH=80 for a typical text file). This would allow the browser to pick a font which fits the entire text in the current window. Unfortunately this isn't very widely supported. Notes: Although text-level markup is allowed inside PRE, not all tags are supported. A P tag is strictly not permitted inside PRE, but if a browser encounters one, it should treat it as two newlines. Since HTML tags are permitted inside PRE, you cannot just "insert" a text file into an HTML document by slapping
andaround them. You have to convert the &, < and > characters into entities first. P - Paragraph Appearance:
[
] Attributes:ALIGN=left|center|right Contents:TT, I, B, U, STRIKE, BIG, SMALL, SUB, SUP, EM, STRONG, DFN, CODE, SAMP, KBD, VAR, CITE, A, APPLET, IMG, FONT, BASEFONT, BR, MAP, INPUT, SELECT, TEXTAREA and plain text. May occur in:BODY, DIV, CENTER, BLOCKQUOTE, FORM, TH, TD and DD, LI, ADDRESS. The P tag is used to indicate paragraphs. The optional attribute ALIGN indicates the preferred alignment for the contents of this paragraph. Support for ALIGN=RIGHT is not as large as support for the other two. Note that ALIGN=LEFT is the default. Notes: Some browsers render extra whitespace when multiple empty paragraphs are used in sequence. This is not required by the specs, so do not count on this to get vertical whitespace in your document. When a paragraph has the ALIGN=CENTER or ALIGN=RIGHT attribute, some browsers do not use the default alignment for the next paragraph unless this paragraph is explicitly closed. In the very first version of HTML, the P tag was an empty tag like BR. Some references and books still claim that this is the case. However, HTML 2.0 defines the P tag as a container, and there is no difference between a paragraph with and one without explicit alignment. Despite the above, some browsers treat the closing tag as an opening tag - they insert an extra paragraph break there. SAMP - Sample text Appearance: Attributes:None. Contents:TT, I, B, U, STRIKE, BIG, SMALL, SUB, SUP, EM, STRONG, DFN, CODE, SAMP, KBD, VAR, CITE, A, APPLET, IMG, FONT, BASEFONT, BR, MAP, INPUT, SELECT, TEXTAREA and plain text. May occur in:BODY, DIV, CENTER, BLOCKQUOTE, FORM, TH, TD, DT, DD, LI, P, H1, H2, H3, H4, H5, H6, PRE, ADDRESS, TT, I, B, U, STRIKE, BIG, SMALL, SUB, SUP, EM, STRONG, DFN, CODE, SAMP, KBD, VAR, CITE, FONT, A, APPLET, CAPTION. SAMP is used to indicate a sample of text which should be used literally. For example, "The text General Protection Fault is well known to Windows users." It differs from KBD text in that KBD text indicates text the user must enter, whereas SAMP text can also be output. Notes: Do not use SAMP if your text requires a monospaced font; use TT instead. SCRIPT - Inline scripts Appearance: Attributes:None. Contents:Plain text, but should be a valid script. May occur in:HEAD. The SCRIPT tag is included only to ensure upward compatibility. Newer versions of HTML will include support for inline scripts, which should be contained in this tag. The tag should contain a valid script. Note that current browsers are only required to hide the contents of the SCRIPT tag, it does not have to use the information contained therein. In the meantime, if you need scripts in your documents, put them inside HTML comments. Notes: Not all browsers support scripts. Since not all browsers will hide the tag's contents, you may want to enclose it in comments. Note that if your script uses the ">" or "--" symbols, some browsers may end the comment accidentally. SELECT - Selection list Appearance: Attributes:NAME=string, SIZE=n, MULTIPLE Contents:OPTION. May occur in:BODY, DIV, CENTER, BLOCKQUOTE, FORM, TH, TD, DT, DD, LI, P, H1, H2, H3, H4, H5, H6, PRE, ADDRESS, TT, I, B, U, STRIKE, BIG, SMALL, SUB, SUP, EM, STRONG, DFN, CODE, SAMP, KBD, VAR, CITE, FONT, A, APPLET, CAPTION, but must be inside a FORM. The SELECT tag is used inside forms to generate a list of items from which the user can select one or more. Each item is listed in an OPTION tag. The value of the selected OPTION tag is assigned to the NAME of the SELECT tag, and both are sent to the server when the form is submitted. The SIZE attribute indicates how many items are visible at once. If set to one, you will get a drop-down list. If it's more than one, you will get a scrollable list. If the MULTIPLE attribute is selected, the user can select more than one item from the list. Notes: Exactly how a user can select more than one item at once is dependant on his platform, so do not include "instructions" on how to do this. They may be wrong and can cause a lot of confusion. If you use MULTIPLE, set the SIZE to more than one. This makes it easier to select more than one item. SMALL - Smaller text Appearance: Attributes:None. Contents:TT, I, B, U, STRIKE, BIG, SMALL, SUB, SUP, EM, STRONG, DFN, CODE, SAMP, KBD, VAR, CITE, A, APPLET, IMG, FONT, BASEFONT, BR, MAP, INPUT, SELECT, TEXTAREA and plain text. May occur in:BODY, DIV, CENTER, BLOCKQUOTE, FORM, TH, TD, DT, DD, LI, P, H1, H2, H3, H4, H5, H6, PRE, ADDRESS, TT, I, B, U, STRIKE, BIG, SMALL, SUB, SUP, EM, STRONG, DFN, CODE, SAMP, KBD, VAR, CITE, FONT, A, APPLET, CAPTION. The SMALL tag (as well as BIG) is new. A browser should draw the enclosed text in a smaller font if available, and ignore the tag otherwise. Since this tag is new, support for it is not universal. The FONT tag can do the same, with SIZE="-1". Notes: Nesting SMALL tags may produce text in a smaller font than with just one SMALL tag, but this is not required by the specs (although it is recommended). It is legal to nest BIG and SMALL, although the results are undefined. SMALL is not supported by all browsers, so you might want to use instead. STRIKE - Strike-through text Appearance:| Average | other category | Misc | ||
|---|---|---|---|---|
| height | weight | |||
| males | 1.9 | 0.003 | ||
| females | 1.7 | 0.002 | ||
. Avoid using pixel widths for a table. They force that the browser window is sized to a particular width to see the entire table, which is not always desirable, let alone possible. Tables are often used for page layout purposes. This is not recommended, since it totally screws up the display for browsers which do not support tables, and it also often gives awkward results on small screens. Earlier drafts of HTML 3.2 allowed the BORDER attribute to be given without value (and then the value defaulted to 1). The final version only permits BORDER=n. The HTML 3 draft did not include the values for the BORDER attribute, so browsers which use this table model might draw a border around your table when you use BORDER=0. An empty table cell is typically drawn differently than a non-empty cell. If you need a table cell with non content, but with the same appareance as a non-empty cell, put " " in the cell. TD - Table cell Appearance: