Unit-2 (HTML) - 1
Unit-2 (HTML) - 1
Unit-2 (HTML) - 1
Contents of the tutorial, shown image(s) (if shown here) and movie(s) (if shown here)
are just compilation of research work/creation of various authors/organizations.
Contents are collected from various research papers, reports, books, websites and other
sources.
HTML is an acronym which stands for Hyper Text Markup Language which is used for creating web
Hyper Text: HyperText simply means "Text within Text." A text has a link within it, is a hypertext.
Whenever you click on a link which brings you to a new webpage, you have clicked on a hypertext.
HyperText is a way to link two or more web pages (HTML documents) with each other.
Markup language: A markup language is a computer language that is used to apply layout and
formatting conventions to a text document. Markup language makes text more interactive and
Web Page: A web page is a document which is commonly written in HTML and translated by a web
browser. A web page can be identified by entering an URL. A Web page can be of the static or
dynamic type. With the help of HTML only, we can create static web pages.
Hence, HTML is a markup language which is used for creating attractive web pages with the help of
styling, and which looks in a nice format on a web browser. An HTML document is made of many
HTML Versions
Since the time HTML was invented there are lots of HTML versions in market, the brief introduction
1. HTML 1.0: The first version of HTML was 1.0, which was the barebones version of HTML
2. HTML 2.0: This was the next version which was released in 1995, and it was standard
language version for website design. HTML 2.0 was able to support extra features such as
form-based file upload, form elements such as text box, option button, etc.
capable of creating tables and providing support for extra options for form elements. It can
also support a web page with complex mathematical equations. It became an official standard
for any browser till January 1997. Today it is practically supported by most of the browsers.
4. HTML 4.01: HTML 4.01 version was released on December 1999, and it is a very stable
version of HTML language. This version is the current official standard, and it provides
added support for stylesheets (CSS) and scripting ability for various multimedia elements.
5. HTML5 : HTML5 is the newest version of HyperText Markup language. The first draft of
this version was announced in January 2008. There are two major organizations one is W3C
(World Wide Web Consortium), and another one is WHATWG( Web Hypertext Application
Technology Working Group) which are involved in the development of HTML 5 version, and
An HTML file is a text file, so to create an HTML file we can use any text editors.
Text editors are the programs which allow editing in a written text, hence to create a web
There are various types of text editors available which you can directly download, but for a
After learning the basics, you can easily use other professional text editors which are,
<!DOCTYPE>
<html>
<head>
</head>
<body>
</body>
</html>
<!DOCTYPE>: It defines the document type or it instruct the browser about the version of HTML.
<html > :This tag informs the browser that it is an HTML document. Text between html tag
describes the web document. It is a container for all other elements of HTML.
<head>: It should be the first element inside the <html> element, which contains the
metadata(information about the document). It must be closed before the body tag opens.
<title>: As its name suggested, it is used to add title of that HTML page which appears at the top of
the browser window. It must be placed inside the head tag and should close immediately. (Optional)
<body> : Text between body tag describes the body content of the page that is visible to the end
user. This tag contains the main content of the HTML document.
<h1> : Text between <h1> tag describes the first level heading of the webpage.
<p> : Text between <p> tag describes the paragraph of the webpage.
Tags: An HTML tag surrounds the content and apply meaning to it. It is written between <
Attribute: An attribute in HTML provides extra information about the element, and it is
applied within the start tag. An HTML attribute contains two fields: name & value.
Syntax
HTML Tags
HTML tags are like keywords which defines that how web browser will format and display the
content. With the help of tags, a web browser can distinguish between an HTML content and a
simple content. HTML tags contain three main parts: opening tag, content and closing tag. But some
When a web browser reads an HTML document, browser reads it from top to bottom and left to
right. HTML tags are used to create HTML documents and render their properties. Each HTML tags
An HTML file must have some essential tags so that web browser can differentiate between a simple
text and HTML text. You can use as many tags you want as per your code requirement.
All HTML tags must enclosed within < > these brackets.
If you have used an open tag <tag>, then you must use a close tag </tag> (except some tags)
Container tags are those tags which are having opening and closing tags and may contain content in
Empty tags are those tags which does not have closing tag such as <br>, <hr> etc.
<HEAD>
<META charset="UTF-8">
</HEAD>
<H1>…. </H1>
<H2>…. </H2>
<H3>…. </H3>
<H4>…. </H4>
<H5>…. </H5>
<H6>…. </H6>
<B>…</B>
<I>….</I>
<U>….</U>
<FONT>…….</FONT>
<A>…..</A>
<OL><LI>…..</LI></OL>
<IMG>
<BR>
<HR>
<TR>…… </TR>
<TH>…..</TH>
<TD>…..</TD>
<FORM>…..</FORM>
<INPUT>
<SELECT>…..</SELECT>
<OPTION>……</OPTION>
<FRAMESET>……</FRAMESET>
<FRAME>
<IFRAME>…...</IFRAME>
Some characters are reserved in HTML. If you use the less than (<) or greater than (>) signs in your
text, the browser might mix them with tags. Character entities are used to display reserved characters
in HTML.
There are a lot of web browser available in the market. All of them interpret and display information
on the screen however their capabilities and structure varies depending upon implementation. But the
most basic component that all web browser must exhibit are listed below:
Controller/Dispatcher
Interpreter
Client Programs
Controller works as a control unit in CPU. It takes input from the keyboard or mouse, interpret it and
Interpreter receives the information from the controller and execute the instruction line by line.
Some interpreter are mandatory while some are optional For example, HTML interpreter program is
Client Program describes the specific protocol that will be used to access a particular service.
HTTP
SMTP
FTP
NNTP
POP