HTML by Ramana
HTML by Ramana
HTML
BY RAMANA
1 What is HTML? 6 HTML Elements
4 HTML Skeleton
5 HTML Comments
BY RAMANA
Agenda
What is HTML?
Proprietary content. ©Great Learning. All Rights Reserved. Unauthorized use or distribution prohibited
What Is HTML ?
BY RAMANA
What is HTML?
HTML
BY RAMANA
Features of HTML
● Markup Language: Text between tags that defines
structure.
BY RAMANA
HTMLEditors
Features of HTML
● Learning curve is very easy (easy to modify).
BY RAMANA
● Case insensitive language.
HTML Editors
● Simple editor: Notepad
● Notepad++
● Atom
BY RAMANA
Notepad
BY RAMANA
BY RAMANA
Notepad++
BY RAMANA
BY RAMANA
Atom
BY RAMANA
BY RAMANA
Sublime Text
BY RAMANA
BY RAMANA
HTMLSkeleton
HTML Skeleton
<!DOCTYPE html>
<html>
<head>
<title></title>
</head>
<body>
</body>
</html>
BY RAMANA
HTMLSkeleton
<!DOCTYPE html>
Instruction to the browser about the HTML version.
<html>
Root element which acts as a container to hold all the code Browser should
know that this an HTML document Permitted content: One head tag
followed by one body tag.
<head>
Everything written here will never be displayed in the browser. It contains
general information about the document - Title, definitions of CSS and
script sheets, and Metadata(information about the document).
<body>
BY RAMANA
HTML comments
● Contains text, images, links which can be achieved through tags.
● Examples:
○ <p> This is our first paragraph. </p>
○ <a href=“https://www.google.com”>Go To Google</a>
○ <img src="photo.jpg">
HTML Comments
● Comments don’t render on the browser.
HTML Elements
● Elements are created using tags.
Basic Structure
○ Takes up full block or width and adds structure in the web page.
○ Always starts from new line, dividing a page into coherent blocks.
○ Example :
■ <p>
■ <div>
■ <h1>...<h6>
BY RAMANA
■ <ol> ■ <ul> ●
Inline Level :
○ Example :
■ <span>
■ <strong>
■ <em>
■ <img>
■ <a>
BY RAMANA
Basic Tags
Basic Tags
● Enclosed within <>
● <title> tag
0 Whatever is written this tag comes up in the web page’s tab. ○ Defines the
title of the page.
○ Syntax: <title>Home</title>
● <p> tag
0 Defines the paragraph.
○ Syntax:<p > This is our first Paragraph </p>
BY RAMANA
List of Self closing/Empty tags
● <hr> tag
○ Stands for horizontal rule. ○ Dividing the web page.
● <br> tag
○ Stands for break line. ○ Moving to next line.
● <img> tag
○ To add images in the web page.
● <h1> tag …… <h6> tag
0 Stands for heading tag.
○ Defines heading of a page.
○ h1 represents most important page in the page. ○ h6 represents least
important page in the page.
BY RAMANA
Basic Tags
● <strong> tag
0 Defines the text to be bold.
○ Replaced <b>tag //HTML5
● <em> tag
0 Defines the text to be italic.
○ Replaced <i>tag//HTML5
● <ol> tag
0 Stands for ordered list.
○ To define series of events that take place in some order.
○ Example making a tea (like a flow chart).
○ <ol>.........</ol>
● <ul> tag
0 Stands for unordered list.
BY RAMANA
Basic Tags
○ To define series of events that take place where order is not important.
○ Example your hobbies.
○ <ul>.........</ul>
● <li> tag
0 Defines the list item.
○ Used inside the ol and ul tag to define the events.
○ <li></li>
BY RAMANA
Basic Tags
○ Difference <div> is block level and <span> is inline level.
● <img> tag
0 Used to add images in a web page. ○ Syntax: <img src=”url”> ○ Self closing
tag.
● <a> tags
0 Used to add links in a web page.
○ <a href=”url”> Name of the link </a>
Attributes
● Properties associated with each tag.
BY RAMANA
Attributes
● Global Attribute:
0 Title : Add extra information(hover).
○ Style : Add style information(font, background, color, size).
BY RAMANA
BY RAMANA