Tags

They are special elements or code defined in a page. The browser interepts something as a tag, and is not displayed in the browser window. HTML elements are of two basic types:

Container elements
Element which include both ON tag < and the OFF tag < / i.e. < ON tag >and < / OFF tag.

e.g. < HTML >, < H1 >, etc.

Empty elements
Elements that have only the ON tag i.e. < ON tag >

i.e.< BR >, < HR >, etc.


List of HTML elements
Container | Empty
ShoeBunkErTM



Container Elements
Note: these elements are not visible in browser
HTML element identifies that the document is an HTML document. It is usually at the begining and end of the HTML document. It in turns contains HEAD and a BODY element, which in turn can contain other elements.
< HTML >

    :other TAGS go here...
< /HTML>

HEAD element contains the information about the document, elements such as TITLE, FONT BGCOLOR, VLINK, etc.. etc. could also be used in HEAD element.

BODY element contains all the text and images that make up the HTML document. It can have atributes and parameters
The parameters to an element are given between the start and the end tags. The attributes of an element are given along with the tag name in the angular brackets of the Tags < >.
< HTML >

    < HEAD >
        < TITLE > The title of the Page < /TITLE >
    < /HEAD >
    < BODY >
    can have BACKGROUND, BGCOLOR, FONT, TEXT, LINK, VLINK, A LINK, LEFTMARGIN, TOPMARGIN, BASEFONT, CENTER as attributes.
    < BODY BACKGROUND="figure.jpg">background images could be used
    < BGCOLOR=color > or < BODY BGCOLOR=attribute TEXT = color background colour could be changed and so also the set the colour of the normal text in the document
    LINK = color VLINK = color ALINK = color changes the colours of links:
    LINK defines color of unvisited links, ALINK defines colour of link as it is being clicked and VLINK defines the colour of a link after it has been visited.
    For ready reference here is a list of few of the color names & attribute
    < BODY LEFTMARGIN=pixel > lets us set the left margin value: a numeral
    < BODY TOPMARGIN=pixel > lets us set the top margin value: a numeral

FONT element is used to give specification of size, colour and font of the text it encloses. It has the following attributes:
< FONT SIZE=value : could be from 1-7, 3 being the default or FONT SIZE=+1 : makes one size bigger from current size.
< FONT COLOR=color > :allows to choose colour of the text.
< FONT FACE =font > : allows to set the name of the font for the text.

BASEFONT element allows to set font size, colour or face of a entire document.
< BASEFONT COLOR=color FACE=font SIZE=value >

CENTER element is used to centre the content between the current left and right margins.
< CENTER >

    the rest of text, object or image goes here...to be centred.
< /CENTER >
Test out this Example1

COMMENT element is used to place any text between the tags which will be ignored by the browser. It helps in viewing the HTML code and understand in a page. One can view any page from the browser by visiting the View menu Source option.
< HTML >
< BODY >
< COMMENT >
    This is the comment line which will be not viewed in the browser
< /COMMENT >

!- an exclamation & hyphen followed by text... is used to create a comment line, after a tag.
< HTML >

    < BODY >< !- Comment goes here...
DIV ALIGN allows the divison alignemets to be set to left, centre or to the right.
< DIV ALIGN=left/centre/right >

PARAGRAPH element is used to insert line break with extra space at the begining as well as alignment ALIGN attribute could be used to align text: left, centre or right
< P > or < /P >: inserts a parah / end.
< P ALIGN=left/centre/right >: allows paragraph alingments.

HEADING element defines six levels of headings. It could be used to give section headings. It is usually written as:
< Hn >: where n is level of heading from 1 to 6; the text goes here...< / Hn >
Note: an extra line is automatically inserted above and below the heading. One can have more sub headings, as well as use the ALIGN attribute to align headings.

Style tags are used to set text characterstics.
< B >: the text goes here as bold.< /B >: end of bold tag.
< I >: the text goes here in Italics.< /I >: end of Italics tag.
< TT >: the text goes here as typewriter font.< /TT >: end of typewriter tag.
< U >: the text goes here as underlined.< /U >: end of underline tag.
< S >: the text goes here as strikedout.< /S >: end of strikedout tag.
< SUP >: the text goes here as superscript.< /SUP >: end of superscript tag.
< S UB>: the text goes here as subscript.< /SUB >: end of subscript tag.
Test out this Example2

Making Lists
OL
: is used as a ordered list in a specific order. It displays the list preceded by Arabic numerals, letters or Roman numerals.
< OL START=value TYPE="A"/"a"/"I"/"i"/"1" >
    :
    :
< /OL >: the end of Ordered list.

UL: is used as an unordered list. One can change the style of the bullet.
< UL TYPE="circle"/"disc"/"square" >

    :
    :
< /UL >
list item

Anchor element alows to create a link to text in the same document or another document in any other computer on the Network. This required linked could created and could be called as a hypertext link. The defines an Anchor element which is a container tag.
< A HREF="URL" >text describing the link< /A >
The above statement is displayed in a browser, the words text describing link appear underlined an in another colour indicating clicking starts execution of the hypertext link.
Note: it could be any file as .HTM, JPG, JPEG or an URL: Uniform Resource Locator which is an address of a page on the WWW
Example:
< A HREF="school.htm">Our School Information< /A >
< A HREF="http://www.domain.nam/file.htm" >information to the site description< /A >
Visit this website for more detailed HTML information
Take a look at my resume http://www.oocities.org/subhankarganguly/resume.htm
HREF attribute selects the hypertext, the control moves to the document specified by the value in the attribute namely the name the location and the name of the page.

Section links can create links to other part of the same document or part of another document.
< A HREF="#sectionname" >link text< /A >: link to another section of the same document.
< A HREF="http://www.domain.nam/file.htm#sectionname" >link text< /A >: link to a section or part of another document.
< A NAME="sectionname" >link text< /A >: naming / bookmark of a section.
< A HREF="graphicobject.gif/graphicobject.jpeg">link text< /A >: links a graphic as a hyperlink to a document / object.

empty tags



Colour Name and Attribute (Hexadecimal RGB value)
Aqua #00FFFF
Black #000000
Blue #0000FF
Fuchsia#FF00FF
Gray #808080
Green #008000
Lime #00FF00
Maroon #800000
Navy #000080
Olive #808000
Purple #800080
Red #FF0000
Silver #C0C0C0
Teal #008080
White #FFFFFF
Yellow #FFFF00

There are many more colors and hex values.
To change the background colour, one can also use contrast colour of the text as #RRGGBB: where RR equals hex value of Red, GG equals hex values of Green and BB equals hex values of Blue.

continue... container elements
Empty container elements
BR break are called as line breaks: inserts a single carriage return in a document, sends the cursor to next line in a document.

< BR >

IMG Image element is used to specify an image to be displayed in a HTML document.
The most widley used image formats are GIF and JPEG format. Image could be linked or in-line(the image appears with the document). It has SCR, ALIGN, BORDER, HEIGHT, WIDTH and ALT as the attributes.
< HTML >
< BODY >

    < IMG SRC=image.gif / image.jpeg ALT=alternate text to display
    ALIGN=left / right / centre BORDER=value HEIGHT=pixel / % ratio WIDTH=pixel >