Please press the "Home" Key to back here.
Group A
An anchor marks the beginning and/or end of a hypertext link.
<a> anchor
name=text
This allows the anchor to be the destination of a link. This means you can direct a link elsewhere to a specific part of a document. When using the name
attribute, you do not need close the tag with </a>
.
<a name="bgsound">
href
Use this to tell the browser where you wish a link to lead. This can be used for links to elsewhere in the document (as defined using the name
attribute),
to remote locations, or to a destination within a remote document. The live area will be any text and images located between the tags.
This link takes you to the <a href="http://www.ctcc.gov.za/ccchome.html">Cape Town <img src="graphics/cape_sm.jpg"></a> home page.
The border around the graphic indicates that it is a live link. <br>
Check out this document's section on <a href="#bgsound">Background Sound.</a> <br>
This link takes you to the <a href="../setup/sterolab/sterolab.htm#facts">Facts</a> section of my Stereolab page.
This link takes you to the Cape Town home page.
The border around the graphic indicates that it is a live link.
Check out this document's section on Background sound.
This link takes you to the Facts section of my Stereolab page.
href
with mailto
You can also use the href
attribute to to allow the reader to mail you.
Mail me at <a href="mailto:benz@coomedia.com">html@woodhill.co.uk</a>.
Mail me at benz@coomedia.com.
A logical style used when providing address information, often at the top or bottom of the document.
<address>
University of Bath
<address>
University of Bath<br>
Claverton Down<br>
Bath<br>
UK<br>
</address>
Claverton Down
Bath
UK
Used in an image map definition to specify a live area. Must be used within the
<area> image map area
<map>
tags. An arbitrary number of <area>
tags may be specified. If two areas intersect, the one which appears first in the map definition takes precedence in the overlapping region. For more information, see the section dedicated to Image maps.
shape="rect | circle | poly | default"
coords
attribute.
coords="x1,y1,x2,y2 | x,y,r | x1,y1,x2,y2,x3,y3..."
shape
attribute, except when it is set to default.
nohref
<area shape="rect" coords="2,3,86,30" href="http://www.yahoo.com/">
<area shape="circle" coords="160,15,16" href="http://www.netscape/">
<area shape="polygon" coords="273,0,252,3,245,11" href="../setup/welcome.htm">
<area shape="default" nohref>
<strong>
.
Cars are <b>not</b> toys. They are 1 ton killing machines.
<base>
href
is the only attribute and is always required. Note that you must include the full URL and the filename of the document that the
<base href="http://www.provider.com/user/document.htm">
<basefont>
<font>
to set a default font size. Always used with the size
attribute.
size=value
<basefont size=2>
<font size=+1>Tottenham Hotspur</font>
<basefont size=4>
<font size=+1>Chelsea</font>
<bgsound> background sound
src="URL"
loop="n | infinite"
n=-1
, or if loop=infinite
, it will play indefinately.
<bgsound src="sounds/blakmeat.wav" loop="2">
<blink>
Blinking flip: <blink>flip</blink>
<blockquote>
<cite>
.
The best bit was when when Hamlet said,
<blockquote>
To be, or not to be.<br>
That is the question.<br>
</blockquote>
But then everyone knows that.
To be, or not to be.But then everyone knows that.
That is the question.
<body>
<body>
element contains all the information which is part of the document, as opposed to information about the document, which should be in the <head>
.
The <body>
tag should be placed directly after the closing head tag, </head>
. The closing body tag, </body>
should be placed as the pen-ultimate line of the document, directly before the </html>
tag.
<html>
<head>
<title>A Shell Document</title>
</head>
<body>
The document in here
</body>
</html>
bgcolor=#hexcolour
, text=#hexcolour
, link=#hexcolour
, vlink=#hexcolour
, alink=#hexcolour
text
controls the main body text,
link
controls unvisited links, vlink
controls visited links and alink
controls active links. All of these attributes are optional.
The colours are described in hexidecimal.
<body bgcolor="#ffffd8" text="#000000" link="#0000ff" vlink="#ff0000" alink="#00a000">
background=URL
<body background="graphics/brick.jpg" text="#FFFFFF">
<br> break
This text is on one line.<br>
This text is on the next line.
clear=left|right|all
<img align=right src="graphics/cliff.gif">
This text is on one line.<br clear="all">
This text is on the line below the graphic.
<caption> table caption
<center>
<center>
This text is in the middle of the line.
</center>
<cite>
<blockquote>
.
Listen to Radio 1's <cite>Evening Session</cite> for great new music.
<code>
<TT>
and <PRE>
.
The logical style <code>code</code> is used to display examples of programming code.
code
is used to display examples of programming code.
<!-- text --> comment
<!-- This is a comment and will not be displayed -->
<dd> definition list definition
<dir> directory list
<dl> definition list
<dt> definition list term
Group E
A logical style used to give emphasis to a section of text. Usually rendered in italic.
See also:
<em> emphasis
<strong>
.
Group F
Tricky is the <em>most original</em> artist currently on the British music scene.
Tricky is the most original artist currently on the British music scene.
Used to change the look of the text.
<font>
size=value|+-value
Used to change text size. Can be used relatively (see basefont
) or absolutely. Valid in the range 1-7.
Make the text <font size=+1>a bit bigger</font>,
<font size=-1>a bit smaller</font>,
<font size=7>huge</font> or
<font size=1>tiny</font>.
Make the text a bit bigger,
a bit smaller,
huge or
tiny.
color=#hexvalue|colourname
Used to change text colour (only in Netscape 2 and MS Explorer). Colours can be described in hexidecimal or by name.
<font color="#00FF00">green</font>
<font color="purple">purple</font>
green
purple
face=fontname1,fontname2,...
Microsoft Internet Explorer only. Used to specify text font from a list of font faces. The list of font faces provides the browser with a choice in order of preference, depending on which fonts are installed on the user's system.
<font face="Arial,Lucida Sans,Gill Sans">This will probably display in Arial.</font>
<font face="Courier,System,MS Sans Serif">This will probably dispaly in Courier.</font>
This will probably display in Arial.
This will probably dispaly in Courier.
Click here to learn all about creating forms.
<form>
Information on frames will appear here soon. Meanwhile, try the page on frames.
Group H
<frame>
Renders text as a heading, the rendering depending on the level of heading selected. Headings are automatically spaced from the body text.
<h1>
,<h2>
,<h3>
,<h4>
,<h5>
,<h6> heading style
<h1>A Level 1 Heading</h1>
Some text.
<h2>A Level 2 Heading</h2>
Some more text.
A Level 1 Heading
Some text.
A Level 2 Heading
Some more text.
The head element contains all the information about the document. It does not contain any text which is part of the document, this is in the
<head>
body
.
The <head>
would follow the <html>
tag and precede the <body>
element.
A shell document would therefore follow the following format:
<html>
<head>
<title>HTML Commands guide: A Shell Document</title>
</head>
<body>
The document in here
</body>
</html>
This produces a horizontal line across the screen. By default the line will be narrow and span the screen within the current indents, eg. those created by a
<hr> horizontal rule
<blockquote>
or list
tag.
align=left|right|clear
Justifies the line left, right or centre (default).
size=value
Increases the vertical height (width) of the line, in pixels.
width=value|percent
Sets the horizontal length of the line in pixels or percent. Note: use <size>
to set what most people would call the line width!
noshade
Turns off the bevelling effect added to lines by some browsers.
<hr align=right size=20 width=400 noshade>
Placed at the beginning and end of the document to declare the type of document.
A shell document would therefore follow the following format:
<html>
<html>
<head>
<title>HTML Commands guide: A Shell Document</title>
</head>
<body>
The document in here
</body>
</html>