HTML
HTML
Introduction
HTML stands for Hyper Text Markup Language. It is a formatting
language used to define the appearance and contents of a web
page. It allows us to organize text, graphics, audio, and video on a
web page.
Key Points:
The word markup refers to the symbols that are used to define
structure of the text. The markup symbols tells the browser how
to display the text and are often called tags.
HTML Versions
Version Year
HTML 1.0 1991
HTML 2.0 1995
HTML 3.2 1997
HTML 4.0 1999
XHTML 2000
:
HTML5 2012
HTML Tags
Tag is a command that tells the web browser how to display the text,
audio, graphics or video on a web page.
Key Points:
They start with a less than (<) character and end with a greater
than (>) character.
Most of the tags usually occur in pair: the start tag and the
closing tag.
The start tag is simply the tag name is enclosed in angle bracket
whereas the closing tag is specified including a forward slash
(/).
Some tags are the empty i.e. they don’t have the closing tag.
The starting and closing tag name must be the same. For
example <b> hello </i> is invalid as both are different.
If you don’t specify the angle brackets (<>) for a tag, the
browser will treat the tag name as a simple text.
Tag Description
<html>
Specifies the document as a web page.
</html>
<head> Specifies the descriptive information about the web
</head> documents.
<title> </title> Specifies the title of the web page.
<body>
Specifies the body of a web document.
</body>
<html>
<head> Heading goes here…</head>
<title> Title goes here…</title>
<body> Body goes here…</body>
</html>
Formatting Tags
The following table shows the HTML tags used for formatting the
text:
Tag Description
<b> </b> Specifies the text as bold. Eg. this is bold text
It is a phrase text. It specifies the emphasized text. Eg.
<em> </em>
Emphasized text
<strong> It is a phrase tag. It specifies an important text. Eg. this
</strong> is strong text
:
<i> </i> The content of italic tag is displayed in italic. Eg. Italic
text
<sub> </sub> Specifies the subscripted text. Eg. X1
<sup> </sup> Defines the superscripted text. Eg. X2
Specifies the inserted text. Eg. The price of pen is now
<ins> </ins>
2015.
Specifies the deleted text. Eg. The price of pen is now
<del> </del>
2015.
<mark>
Specifies the marked text. Eg. It is raining
</mark>
Table Tags
Following table describe the commonaly used table tags:
Tag Description
<table> </table> Specifies a table.
<tr> </tr> Specifies a row in the table.
<th> </th> Specifies header cell in the table.
<td> </td> Specifies the data in an cell of the table.
<caption> </caption> Specifies the table caption.
<colgroup> Specifies a group of columns in a table for
</colgroup> formatting.
List tags
Following table describe the commonaly used list tags:
Tag Description
<ul> </ul> Specifies an unordered list.
<ol> </ol> Specifies an ordered list.
<li> </li> Specifies a list item.
:
<dl> </dl> Specifies a description list.
<dt> </dt> Specifies the term in a description list.
<dd> </dd> Specifies description of term in a description list.
Frames
Frames help us to divide the browser’s window into multiple
rectangular regions. Each region contains separate html web page
and each of them work independently.
The following table describes the various tags used for creating
frames:
Tag Description
It is replacement of the <body> tag. It doesn’t contain the
<frameset>
tags that are normally used in <body> element; instead it
</frameset>
contains the <frame> element used to add each frame.
<frame>
Specifies the content of different frames in a web page.
</frame>
It is used to set the default target frame in any page that
<base>
contains links whose contents are displayed in another
</base>
frame.
Forms
Forms are used to input the values. These values are sent to the
server for processing. Forms uses input elements such as text fields,
check boxes, radio buttons, lists, submit buttons etc. to enter the
data into it.
:
The following table describes the commonly used tags while creating
a form:
Tag Description
<form> </form> It is used to create HTML form.
<input> </input> Specifies the input field.
<textarea> Specifies a text area control that allows to enter
</textarea> multi-line text.
<label> </label> Specifies the label for an input element.
Print Page
Advertisements
: