HTML Crib sheet
Simple Index / Glossary of HTML Tags
The page heading above is contructed as follows
<H1 ALIGN=CENTER> Simple Index / Glossary of HTML Tags</H1>
This web page is being written step by step as I read and learn about each tag and HTML.
I am writing it to do the following;
- Produce a simple index list of tag which I can refer to as I learn HTML
- Allow me to try out the tag and their effects by using them to demostrate thier
function in this simple index
- Provide a simple reference that anyone learning HTML can use
There may well be inaccuracies in my descriptions of the tag, or examples of bad practice.
These should hopefully be corrected over time as I learn more about HTML.
So please do not be anoyed or offended if you find any mistakes etc.
But do drop me a line and educate me on what I may not understand.
Best Wishes to you all!
Contents
- &
- ! - Comment tag in the source code
- A - Anchor & Hyperlinks
- ADDRESS - Define content as an Adress
- ALIGN - Format text alignment to Left, Center, Right
- ASCII Characters - The ASCII character set
- BLOCKQUOTE - Define content as a Quote from an external source
- BODY - Defines the content as the 'body' of the document
- BR - Line break, like a carriage return i.e. start a new line
- CITE - Defines the content as a citation
- CODE - Defineds the content as code e.g. computer program listing
- DOCTYPE - Declares the html document type
- DL -
- DT -
- DD -
- EM - Add Emphasis to the following text
- Hx - Formats the following text as a heading, x = 1 to 6
- HEAD - Defines the content as the header of the html document
- HTML - Defines the content as HTML
- HR - Horizontal rule. Draws a line across the page
- I - Formats the follwing text as itlaic
- IMG - Embeds an image into the doucment
- KBD - Defines the foolowing text as to be typed by the user
- LI - List item to occur in an unordered or ordere list
- OL - Defines an ordered list
- P - Defines the follwing content as a paragraph
- PRE - Forces the web broswer to use the formatting in the source code
- SAMP -
- SMALL - Set the font size to small
- STYLE defines the formatting of the text and/or the document
- TABLE - Defines a table
- TD - Table Data for a cell in a table
- TH - Table header, defines a header for a table
- TITLE - Deinfes the follwing text as the title of the html page
- TR - Table row, starts a new row in a table
- UL - Defines an Unordered list
All HTML documents should have a type declaration at the top.
The decalaration content is not displayed in the web browsers.
The declaration format is as follows;
Example; <DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2//EN">
The meaning and purpose of each part of this declaration is as follows;
TO BE COMPLETED
Contents
Example; <EM>Emphasis tag</EM>
The Emphasis tag is used to emphasis a important or more significant pice of text from the
rest of the doucment / section / page
The emphasis tag does not give control over how the emphasis is performed.
This is determined by the browser and its settings
Contents
Example; <H2>Heading tag</H>
- <Hx> starting tag, where x = 1 through to 6
- "Heading tag" = The text for your heading
- </Hx> Ending tag, where x = 1 through to 6
-
1 = Top level heading, the largest
-
2 = 2nd level heading
-
3 = 3rd Level heading
-
4 = 4th level heading
-
5 = 5th level heading
-
6 = 6th level heading
Note, levels 5 and 6 may not be shown on all web browsers consistantly or reliably.
Use with some care or simply avoid using them.
Contents
Example; <P {ATTRIBUTE}>This is a paragrah</P>
<P ALIGN=LEFT>
The Paragraph tag is used to declare a section of text to be of the same paragraph.
A line break will be inserted at the start of the paragraph.
Further white spaces and white lines in the source will be ignored.
Optional attibutes can be used to set the paragraph formatting & style.
<P ALIGN=CENTER>
A line break is inserted. The Text aligment is now set to centre.
Further white spaces and white lines in the source will be ignored.
<P ALIGN=RIGHT>
A line break is inserted. The Text aligment is now set to right.
Further white spaces and white lines in the source will be ignored.
This sentence is a line break away from the previous sentence in the source.
This can aid readability of the source but appears to be part of the paragraph above in the browser view.
</P>
The text now retruns to the normal alignment set outside the paragraph tag.
Contents
This is a biggy! Text copied from other site - re-write
Defines a style in a document.
The style element goes in the head section. If you want to include a style sheet in your page,
you should define the style sheet externally, and link to it using <link>>
<head>
<style type="text/css">
h1 {color: red}
h3 {color: blue}
</style>
</head>
See http://www.w3schools.com/css/css_reference.asp
Contents
Top of Page
(Updated: 25th August 2008)