Introduction To HTML

Download as pptx, pdf, or txt
Download as pptx, pdf, or txt
You are on page 1of 20

Introduction to HTML

What is HTML ?
• Hyper Text Markup Language
• Most widely used language on Web to develop webpages
• HTML was created by Berners-Lee in late 1991
• HTML 2.0 was the first standard HTML specification
published in 1995.
• HTML 4.01 was a major version of HTML published in late
1999.
• Currently we are having HTML-5 version which is an
extension to HTML 4.01, published in 2012
Hyper Text Markup Language
Hyper text refers to the way in which Web pages (HTML documents) are linked
together. Thus, the link available on a webpage is called Hypertext.

• Hypertext is text which contains links to other


texts

• HTML is a Markup Language which means you


use HTML to simply "mark-up" a text document
with tags that tell a Web browser how to
structure it to display
HTML Tags
• HTML tags are enclosed within angle braces. <TagName>
• Most of the tags have their corresponding closing tags. <TagStart></TagEnd>
• Example:
• <html>/html>
• <body></body>
HTML Element
• An element in HTML represents some kind of structure or semantics and
generally consists of a start tag, content, and an end tag
HTML ATTRIBUTES
• An attribute is used to define the characteristics of an HTML element and is
placed inside the element's opening tag. All attributes are made up of two parts:
a name and a value

Example:
<p align=“right”> content </p>
HTML ATTRIBUTES
The below example shows three possible values of align attribute: left,
center and right
HTML Formatting
Side note: all the tags will have a starting tag as
well as an ending tag
Like; <b></b>
HTML Images
• Use ‘img’ tag
• ‘src’ means source of image
• ‘alt’ gives alternate text if the image doesn’t load
successfully.

Side note: If the image is in the


same folder as the .html file, one
can just write the name of the
image as the value of the src
attribute, but if the image is not in
the same file, one will have to give
the entire path for the image
HTML Tables
• Use of table tag
• <tr> for rows
• <th> for column heading
• <td> for column
HTML Tables (Rowspan)
HTML Tables (Colspan)
HTML Lists
• <ul>− An unordered list
• <ol>− An ordered list
• <li>− item in list
HTML Links
• A link is specified using HTML tag.
• The tag is called the anchor tag and anything between the opening tag and the closing
tag becomes part of the link.
• ‘href’ is used to create hyperlink

Example:
<a href="https://www.google.com/"> Visit Google! </a>
<a href="secondPage.html"> Go to second page </a>
HTML Button
<button> tag is used to create a clickable button within HTML form on your
webpage. You can put content like text or image within the <button>…</button>
tag.
There are different types of buttons that includes submit type, reset type, etc.

There are two ways in which you can use a button to link your
webpages
1. <a href=“next.html"> <button> next</button></a>
(the hyperlink will become a button with no highlighted portion )

2. <button><a href=“back.html"> back </a> </button>


(the button will become a hyperlink)
HTML Buttons
HTML Block
• <div> tag
• Used for grouping of various HTML elements, or making partitions.
HTML Forms
• HTML Form is a document which stores
information of a user on a web server using
interactive controls.
• An HTML form contains different kind of
information such as username, password,
contact number, email id etc.
• The elements used in an HTML form are check
box, input box, radio buttons, submit buttons
etc. Using these elements, the information of a
user is submitted on a web server.
• The form tag is used to create an HTML form
Example of HTML Forms
That’s all..

You might also like