SlideShare a Scribd company logo
HTML (HYPERTEXT MARKUP LANGUAGE)
INTRODUCTION TO HTML
• What is HTML?
• HTML is the language used to create the websites you visit everyday.
It provides a logical way to structure content for websites.
• Let's analyze the acronym "HTML," as it contains a lot of useful
information. HTML stands for HyperText Markup Language.
• A markup language is a computer language that defines the structure
and presentation of raw text. Markup languages work by surrounding
raw text with information the computer can interpret, "marking it up"
to be processed.
!DOCTYPE
• Whether you realize it or not, when you read text, your brain must
first identify the text's language. If you can understand that
language, then your brain immediately begins to interpret the text.
This same process happens whether you're reading a street sign, a
book, or a name tag.
• Web browsers work in a similar way. They must know what language
a document is written in before they can process its contents.
• You can let web browsers know that you are using HTML by starting
your document with a document type declaration.
• The declaration looks like this: <!DOCTYPE html>
• This declaration is an instruction. It tells the browser what type of document
to expect, along with what version of HTML is being used in the document.
• <!DOCTYPE html> must be the first line of code in all of your HTML
documents. If you don't use the declaration, your HTML code will likely still
work, however, it's risky. For now, the browser will correctly assume that the
HTML in <!DOCTYPE html> is referring to HTML 5 as it is the current
standard.
• To make sure your document is forever interpreted correctly, always include
• <!DOCTYPE html> at the very beginning of your HTML documents.
• The <!DOCTYPE html> declaration is only the beginning, however. It
indicates to the browser that you will use HTML in the document, but
it doesn't actually add any HTML structure or content.
• To create HTML structure and content, we must add opening and
closing <html> tags, like so:
• Anything between the opening <html> and closing </html> tags will
be interpreted as HTML code. Without these tags, it's possible that
browsers could incorrectly interpret your HTML code.
Html (hypertext markup language)
• HTML Anatomy
• Before we move forward, it's important that we discuss how HTML elements are
structured.
• In this example, the paragraph element is made up of one opening tag <p> , the
“Hello world!” text, and a closing tag </p>
• Let's quickly review each part of the tag pictured:
• HTML Tag - The element name, surrounded by an opening (<) and closing (>)
angle bracket.
• HTML element (or simply, element) - a unit of content in an HTML document
formed by HTML tags and the text or media it contains.
• Opening tag - the first HTML tag used to start an HTML element. The tag type is
surrounded by opening and closing angle brackets.
• Element content - The information (text or other elements) contained between
the opening and closing tags of an HTML element.
• Closing tag - the second HTML tag used to end an HTML element. Closing tags
have a forward slash (/) inside of them, directly after the left angle bracket.
• Most elements require both opening and closing tags, but some call for a single
THE HEAD
• So far we've done two things:
• Declared to the browser that your code is HTML.
• Added the HTML element <html> that will contain the rest of
your code.
• Let's also give the browser some information about the page.
We can do this by adding a <head> Element.
• element contains the metadata for a web page. Metadata is
information about the page that isn't displayed directly on the
web page. You'll see an example of this in the next exercise.
• The opening and closing head tags <head></head> typically
appear as the first item after your first HTML tag.
PAGE TITLES
• What kind of metadata about the web page can the <head>
element contain?
• The browser displays the title of the page because the title can
be specified directly inside of the <head> element, by using
a title tag.
• If we were to open a file containing the HTML code in the
example above, the browser would display the words “my first
webpage” in the title bar (or in the tab's title).
THE BODY
• We've added some HTML, but still haven't seen any results in
the web browser to the right. Why is that?
• Before we can add content that a browser will display, we have
to add a body to the HTML file. Only content inside the opening
and closing body tags can be displayed to the screen.
• Once the file has a body, many different types of content –
including text, images, and buttons – can be added to the
body.
SELF-CLOSING TAG
• Thus far we have only seen HTML elements with an opening and a
closing tag. A few types of elements, however, require only one tag.
• Self-closing elements contain all the information the browser needs
to render the element inside a single tag. Also, because they are
single tags, they cannot wrap around raw text or other elements.
• The line break element <br /> is one example of a self-closing tag.
You can use it anywhere within your HTML code. The result is a line
break in the browser.
• Without the break tag, the browser would render line one and line
two on the same line.
HTML STRUCTURE
• HTML documents are organized as a collection of parent-child
relationships. When an element is contained inside another
element, it is considered the child of that element. The child
element is said to be nested inside of the parent element.

More Related Content

PPTX
Lecture 2 introduction to html basics
DOCX
Htmlnotes 150323102005-conversion-gate01
PPTX
Introduction to basic HTML [Librarian edition]
PPT
Introduction to html
PDF
Code This, Not That: 10 Do's and Don'ts For Learning HTML
PPTX
Hypertext markup language (html)
PPT
Html for beginners part I
Lecture 2 introduction to html basics
Htmlnotes 150323102005-conversion-gate01
Introduction to basic HTML [Librarian edition]
Introduction to html
Code This, Not That: 10 Do's and Don'ts For Learning HTML
Hypertext markup language (html)
Html for beginners part I

What's hot (20)

PPTX
The Difference between HTML, XHTML & HTML5 for Beginners
PPT
Html presantation
PPTX
HTML- Hyper Text Markup Language
PDF
Html Tutorial
DOC
Learn html from www
PPTX
Introduction to html fundamental concepts
PPTX
Html Tutorial
PPTX
How the Web Works Using HTML
PPTX
An Introduction to HTML
PDF
Html basics
PPT
Introduction to HTML
PPTX
HTML5 Topic 1
PPT
HTML Introduction
PDF
PDF
Html - Tutorial
DOCX
Summary of-xhtml-basics
PPTX
1 introduction to html
PPT
Introduction to HTML
PPTX
A109 base code html
The Difference between HTML, XHTML & HTML5 for Beginners
Html presantation
HTML- Hyper Text Markup Language
Html Tutorial
Learn html from www
Introduction to html fundamental concepts
Html Tutorial
How the Web Works Using HTML
An Introduction to HTML
Html basics
Introduction to HTML
HTML5 Topic 1
HTML Introduction
Html - Tutorial
Summary of-xhtml-basics
1 introduction to html
Introduction to HTML
A109 base code html
Ad

Similar to Html (hypertext markup language) (20)

PPTX
WEB TECHNOLOGY in recent years 122334445
PDF
html.pdf
PDF
WEB PROGRAMMING bharathiar university bca unitII
PPTX
PDF
Html notes
PDF
htmlnotes Which tells about all the basic
PDF
htmlnotes-180924151434.pdf dafdkzndsvkdvdd
PDF
HTML Presentation
PDF
"Innovative Web Design & Development Hub
PPTX
HTML.pptx
PPTX
Week-1_PPT_WEBAPPS-done.pptx
PPTX
001-Hyper-Text-Markup-Language-Lesson.pptx
PPTX
HTML/HTML5
PPTX
Unit 2 Internet and web technology CSS report
PDF
Day1-HTML-CSS some basic css and html.pdf
PPTX
DOCX
HTML Notes And Some Attributes
PPTX
HTMLHTML HTML ghdgsahdaHTML HTML ghdgsahda.pptx
PPTX
Html and Css Student Education hub point.pptx
PPT
Web forms and html (lect 1)
WEB TECHNOLOGY in recent years 122334445
html.pdf
WEB PROGRAMMING bharathiar university bca unitII
Html notes
htmlnotes Which tells about all the basic
htmlnotes-180924151434.pdf dafdkzndsvkdvdd
HTML Presentation
"Innovative Web Design & Development Hub
HTML.pptx
Week-1_PPT_WEBAPPS-done.pptx
001-Hyper-Text-Markup-Language-Lesson.pptx
HTML/HTML5
Unit 2 Internet and web technology CSS report
Day1-HTML-CSS some basic css and html.pdf
HTML Notes And Some Attributes
HTMLHTML HTML ghdgsahdaHTML HTML ghdgsahda.pptx
Html and Css Student Education hub point.pptx
Web forms and html (lect 1)
Ad

Recently uploaded (20)

PDF
Anesthesia in Laparoscopic Surgery in India
PDF
The Lost Whites of Pakistan by Jahanzaib Mughal.pdf
PPTX
Lesson notes of climatology university.
PDF
VCE English Exam - Section C Student Revision Booklet
PDF
Trump Administration's workforce development strategy
PDF
A GUIDE TO GENETICS FOR UNDERGRADUATE MEDICAL STUDENTS
PDF
2.FourierTransform-ShortQuestionswithAnswers.pdf
PDF
3rd Neelam Sanjeevareddy Memorial Lecture.pdf
PPTX
202450812 BayCHI UCSC-SV 20250812 v17.pptx
DOC
Soft-furnishing-By-Architect-A.F.M.Mohiuddin-Akhand.doc
PPTX
1st Inaugural Professorial Lecture held on 19th February 2020 (Governance and...
PDF
Yogi Goddess Pres Conference Studio Updates
PPTX
GDM (1) (1).pptx small presentation for students
PPTX
Introduction-to-Literarature-and-Literary-Studies-week-Prelim-coverage.pptx
PPTX
school management -TNTEU- B.Ed., Semester II Unit 1.pptx
PDF
A systematic review of self-coping strategies used by university students to ...
PDF
Supply Chain Operations Speaking Notes -ICLT Program
PDF
RMMM.pdf make it easy to upload and study
PPTX
human mycosis Human fungal infections are called human mycosis..pptx
PPTX
Orientation - ARALprogram of Deped to the Parents.pptx
Anesthesia in Laparoscopic Surgery in India
The Lost Whites of Pakistan by Jahanzaib Mughal.pdf
Lesson notes of climatology university.
VCE English Exam - Section C Student Revision Booklet
Trump Administration's workforce development strategy
A GUIDE TO GENETICS FOR UNDERGRADUATE MEDICAL STUDENTS
2.FourierTransform-ShortQuestionswithAnswers.pdf
3rd Neelam Sanjeevareddy Memorial Lecture.pdf
202450812 BayCHI UCSC-SV 20250812 v17.pptx
Soft-furnishing-By-Architect-A.F.M.Mohiuddin-Akhand.doc
1st Inaugural Professorial Lecture held on 19th February 2020 (Governance and...
Yogi Goddess Pres Conference Studio Updates
GDM (1) (1).pptx small presentation for students
Introduction-to-Literarature-and-Literary-Studies-week-Prelim-coverage.pptx
school management -TNTEU- B.Ed., Semester II Unit 1.pptx
A systematic review of self-coping strategies used by university students to ...
Supply Chain Operations Speaking Notes -ICLT Program
RMMM.pdf make it easy to upload and study
human mycosis Human fungal infections are called human mycosis..pptx
Orientation - ARALprogram of Deped to the Parents.pptx

Html (hypertext markup language)

  • 2. INTRODUCTION TO HTML • What is HTML? • HTML is the language used to create the websites you visit everyday. It provides a logical way to structure content for websites. • Let's analyze the acronym "HTML," as it contains a lot of useful information. HTML stands for HyperText Markup Language. • A markup language is a computer language that defines the structure and presentation of raw text. Markup languages work by surrounding raw text with information the computer can interpret, "marking it up" to be processed.
  • 3. !DOCTYPE • Whether you realize it or not, when you read text, your brain must first identify the text's language. If you can understand that language, then your brain immediately begins to interpret the text. This same process happens whether you're reading a street sign, a book, or a name tag. • Web browsers work in a similar way. They must know what language a document is written in before they can process its contents. • You can let web browsers know that you are using HTML by starting your document with a document type declaration.
  • 4. • The declaration looks like this: <!DOCTYPE html> • This declaration is an instruction. It tells the browser what type of document to expect, along with what version of HTML is being used in the document. • <!DOCTYPE html> must be the first line of code in all of your HTML documents. If you don't use the declaration, your HTML code will likely still work, however, it's risky. For now, the browser will correctly assume that the HTML in <!DOCTYPE html> is referring to HTML 5 as it is the current standard. • To make sure your document is forever interpreted correctly, always include • <!DOCTYPE html> at the very beginning of your HTML documents.
  • 5. • The <!DOCTYPE html> declaration is only the beginning, however. It indicates to the browser that you will use HTML in the document, but it doesn't actually add any HTML structure or content. • To create HTML structure and content, we must add opening and closing <html> tags, like so: • Anything between the opening <html> and closing </html> tags will be interpreted as HTML code. Without these tags, it's possible that browsers could incorrectly interpret your HTML code.
  • 7. • HTML Anatomy • Before we move forward, it's important that we discuss how HTML elements are structured. • In this example, the paragraph element is made up of one opening tag <p> , the “Hello world!” text, and a closing tag </p> • Let's quickly review each part of the tag pictured: • HTML Tag - The element name, surrounded by an opening (<) and closing (>) angle bracket. • HTML element (or simply, element) - a unit of content in an HTML document formed by HTML tags and the text or media it contains. • Opening tag - the first HTML tag used to start an HTML element. The tag type is surrounded by opening and closing angle brackets. • Element content - The information (text or other elements) contained between the opening and closing tags of an HTML element. • Closing tag - the second HTML tag used to end an HTML element. Closing tags have a forward slash (/) inside of them, directly after the left angle bracket. • Most elements require both opening and closing tags, but some call for a single
  • 8. THE HEAD • So far we've done two things: • Declared to the browser that your code is HTML. • Added the HTML element <html> that will contain the rest of your code. • Let's also give the browser some information about the page. We can do this by adding a <head> Element.
  • 9. • element contains the metadata for a web page. Metadata is information about the page that isn't displayed directly on the web page. You'll see an example of this in the next exercise. • The opening and closing head tags <head></head> typically appear as the first item after your first HTML tag.
  • 10. PAGE TITLES • What kind of metadata about the web page can the <head> element contain? • The browser displays the title of the page because the title can be specified directly inside of the <head> element, by using a title tag. • If we were to open a file containing the HTML code in the example above, the browser would display the words “my first webpage” in the title bar (or in the tab's title).
  • 11. THE BODY • We've added some HTML, but still haven't seen any results in the web browser to the right. Why is that? • Before we can add content that a browser will display, we have to add a body to the HTML file. Only content inside the opening and closing body tags can be displayed to the screen. • Once the file has a body, many different types of content – including text, images, and buttons – can be added to the body.
  • 12. SELF-CLOSING TAG • Thus far we have only seen HTML elements with an opening and a closing tag. A few types of elements, however, require only one tag. • Self-closing elements contain all the information the browser needs to render the element inside a single tag. Also, because they are single tags, they cannot wrap around raw text or other elements. • The line break element <br /> is one example of a self-closing tag. You can use it anywhere within your HTML code. The result is a line break in the browser. • Without the break tag, the browser would render line one and line two on the same line.
  • 13. HTML STRUCTURE • HTML documents are organized as a collection of parent-child relationships. When an element is contained inside another element, it is considered the child of that element. The child element is said to be nested inside of the parent element.