Container elements
e.g. < HTML >, < H1 >, etc.
Empty elements
i.e.< BR >, < HR >, etc.
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
BASEFONT element allows to set font size, colour or face of a entire document. CENTER element is used to centre the content between the current left and right margins.
!- an exclamation & hyphen followed by text... is used to create a comment line, after a tag.
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
HEADING element defines six levels of headings. It could be used to give section headings. It is usually written as:
UL: is used as an unordered list. One can change the style of the bullet.
Section links can create links to other part of the same document or part of another document.
There are many more colors and hex values. < BR >
IMG Image element is used to specify an image to be displayed in a HTML document.
Element which include both ON tag < and the OFF tag < / i.e. < ON tag >and < / OFF tag.
Elements that have only the ON tag i.e. < ON tag >
List of HTML elements
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>
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 >
FONT element is used to give specification of size, colour and font of the text it encloses. It has the following attributes:
< /HEAD >< TITLE > The title of the Page < /TITLE >
< 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.
< BODY TOPMARGIN=pixel > lets us set the top margin value: a numeral
< 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 COLOR=color FACE=font SIZE=value >
< CENTER > the rest of text, object or image goes here...to be centred.
< /CENTER >
< HTML >
< BODY >
< COMMENT >This is the comment line which will be not viewed in the browser
< /COMMENT >
< 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 >
< P > or < /P >: inserts a parah / end.
< P ALIGN=left/centre/right >: allows paragraph alingments.
< 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.
< 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.
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 TYPE="circle"/"disc"/"square" >:
< /UL >
:
< 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.
< 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.
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
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.
BR break are called as line breaks: inserts a single carriage return in a document, sends the cursor to next line in a 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 >
Has following attributes: ALIGN, COLOR, SHADE, SIZE, WIDTH
< HR ALIGN = CENTRE/LEFT/RIGHT : specifies the horrizontal alignment.
NOSHADE: displays solid black line with no shade
COLOR=name
SIZE="Thickness" : indicates thickness of line in pixels, default=2
WIDTH="Width" >: horrizontal width of the the line, default width of the page in pixels
< HTML >
< BODY >< LI >: the text goes here...
< /BODY >
< LI >: this is second line of text in the list.
< /HTML >