SlideShare une entreprise Scribd logo
1  sur  40
HTML
Source: https://www.w3schools.com/html/default.asp
Prepared by: Engr. Juvywen M. Pollentes
 TOPICS:
HTML Introduction
HTML Editors
HTML Basics
HTML Elements
What is HTML?
 HTML is the standard markup language for creating Web
pages.
 HTML stands for Hyper Text Markup Language
 HTML describes the structure of Web pages using
markup
 HTML elements are the building blocks of HTML pages
 HTML elements are represented by tags.
 HTML tags label pieces of content such as "heading",
"paragraph", "table", and so on.
 Browsers do not display the HTML tags, but use them to
render the content of the page.
A Simple HTML Document
<!DOCTYPE html>
<html>
<head>
<title>Page Title</title>
</head>
<body>
<h1>My First Heading</h1>
<p>My first paragraph.</p>
</body>
</html>
Example Explained
•The <!DOCTYPE html> declaration defines this document to
be HTML5
•The <html> element is the root element of an HTML page
•The <head> element contains meta information about the
document
•The <title> element specifies a title for the document
•The <body> element contains the visible page content
•The <h1> element defines a large heading
•The <p> element defines a paragraph
HTML Tags
HTML tags are element names surrounded by angle brackets:
<tagname>content goes here...</tagname>
 HTML tags normally come in pairs like <p> and </p>
 The first tag in a pair is the start tag, the second tag is
the end tag
 The end tag is written like the start tag, but with a forward
slash inserted before the tag name
Tip: The start tag is also called the opening tag, and the end
tag the closing tag
Web Browsers
 The purpose of a web browser (Chrome, IE, Firefox,
Safari) is to read HTML documents and display them.
 The browser does not display the HTML tags, but uses
them to determine how to display the document.
HTML Page Structure
Below is a visualization of an HTML page structure:
Note: Only the content inside the <body> section (the white area
above) is displayed in a browser.
The <!DOCTYPE> Declaration
 The <!DOCTYPE> declaration represents the document
type, and helps browsers to display web pages correctly.
 It must only appear once, at the top of the page (before
any HTML tags).
 The <!DOCTYPE> declaration is not case sensitive.
 The <!DOCTYPE> declaration for HTML5 is:
<!DOCTYPE html>
HTML Versions
HTML Editors
Write HTML Using Notepad or TextEdit
 Web pages can be created and modified by using
professional HTML editors.
 However, for learning HTML we recommend a simple text
editor like Notepad (PC) or TextEdit (Mac).
 We believe using a simple text editor is a good way to
learn HTML.
 Follow the four steps below to create your first web page
with Notepad or TextEdit.
Step 1: Open Notepad (PC)
 Windows 8 or later:
 Open the Start Screen (the window symbol at the bottom
left on your screen). Type Notepad.
 Windows 7 or earlier:
 Open Start > Programs > Accessories > Notepad
Step 1: Open TextEdit (Mac)
 Open Finder > Applications > TextEdit
 Also change some preferences to get the application to
save files correctly. In Preferences > Format
> choose "Plain Text"
 Then under "Open and Save", check the box that says
"Ignore rich text commands in HTML files".
 Then open a new document to place the code.
Step 2: Write Some HTML
 Write or copy
some HTML into
Notepad.
Step 3: Save the HTML Page
 Save the file on your computer. Select File > Save as in
the Notepad menu.
 Name the file "index.htm" and set the encoding to UTF-
8 (which is the preferred encoding for HTML files).
You can use either .htm or .html as file extension. There is no
difference, it is up to you.
Step 4: View the HTML Page in Your
Browser
 Open the saved HTML
file in your favorite
browser (double click on
the file, or right-click -
and choose "Open
with").
 The result will look much
like this:
HTML Basic
HTML Documents
 All HTML documents must start with a document type
declaration: <!DOCTYPE html>.
 The HTML document itself begins with <html> and ends
with </html>.
 The visible part of the HTML document is
between <body> and </body>.
HTML Headings
 HTML headings are defined with the <h1> to <h6> tags.
 <h1> defines the most important heading. <h6> defines
the least important heading:
HTML Paragraphs
 HTML paragraphs are defined with the <p> tag:
HTML Links
 HTML links are defined with the <a> tag:
The link's destination is specified in the href attribute.
Attributes are used to provide additional information about HTML
elements.
HTML Images
 HTML images are defined with the <img> tag.
 The source file (src), alternative text (alt), width, and
height are provided as attributes:
HTML Elements
 An HTML element usually consists of a start tag
and end tag, with the content inserted in between:
<tagname>Content goes here...</tagname>
 The HTML element is everything from the start tag to the
end tag:
<p>My first paragraph.</p>
HTML elements with no content are called empty
elements. Empty elements do not have an end tag, such
as the <br> element (which indicates a line break).
Nested HTML Elements
 HTML elements can be nested (elements can contain
elements).
 All HTML documents consist of nested HTML elements.
Example Explained
 The <html> element
defines the whole
document.
 It has a start tag <html>
and an end tag </html>.
 The element content is
another HTML element
(the <body> element).
 The <body> element
defines
the document body.
 It has a start tag
<body> and
an end tag </body>.
 The
element content is
two other HTML
elements (<h1> and
<p>).
 The <h1> element
defines a heading.
 It has a start tag
<h1> and
an end tag </h1>.
 The
element content is:
My First Heading.
 The <p> element
defines
a paragraph.
 It has a start tag
<p> and an end tag
</p>.
 The
element content is:
My first paragraph.
Do Not Forget the End Tag
 Some HTML
elements will display
correctly, even if you
forget the end tag:
Empty HTML Elements
 HTML elements with no content are called empty elements.
 <br> is an empty element without a closing tag (the <br> tag
defines a line break).
 Empty elements can be "closed" in the opening tag like this:
<br />.
 HTML5 does not require empty elements to be closed. But if
you want stricter validation, or if you need to make your
document readable by XML parsers, you must close all HTML
elements properly.
Use Lowercase Tags
 HTML tags are not case sensitive: <P> means the same
as <p>.
 The HTML5 standard does not require lowercase tags,
but W3C recommends lowercase in HTML,
and demands lowercase for stricter document types like
XHTML.
-END-

Contenu connexe

Tendances

Introduction to HTML
Introduction to HTMLIntroduction to HTML
Introduction to HTMLMayaLisa
 
HTML, CSS and Java Scripts Basics
HTML, CSS and Java Scripts BasicsHTML, CSS and Java Scripts Basics
HTML, CSS and Java Scripts BasicsSun Technlogies
 
Html Intro2
Html Intro2Html Intro2
Html Intro2mlackner
 
Intro to HTML & CSS
Intro to HTML & CSSIntro to HTML & CSS
Intro to HTML & CSSSyed Sami
 
HTML Semantic Elements
HTML Semantic ElementsHTML Semantic Elements
HTML Semantic ElementsReema
 
Basic HTML
Basic HTMLBasic HTML
Basic HTMLSayan De
 
Introduction to HTML5
Introduction to HTML5Introduction to HTML5
Introduction to HTML5IT Geeks
 
Intro to HTML and CSS basics
Intro to HTML and CSS basicsIntro to HTML and CSS basics
Intro to HTML and CSS basicsEliran Eliassy
 
Cascading Style Sheets (CSS) help
Cascading Style Sheets (CSS) helpCascading Style Sheets (CSS) help
Cascading Style Sheets (CSS) helpcasestudyhelp
 
(Fast) Introduction to HTML & CSS
(Fast) Introduction to HTML & CSS (Fast) Introduction to HTML & CSS
(Fast) Introduction to HTML & CSS Dave Kelly
 
Html5 tutorial for beginners
Html5 tutorial for beginnersHtml5 tutorial for beginners
Html5 tutorial for beginnersSingsys Pte Ltd
 
Html 5 tutorial - By Bally Chohan
Html 5 tutorial - By Bally ChohanHtml 5 tutorial - By Bally Chohan
Html 5 tutorial - By Bally Chohanballychohanuk
 
Lecture 2 introduction to html
Lecture 2  introduction to htmlLecture 2  introduction to html
Lecture 2 introduction to htmlpalhaftab
 
Eye catching HTML BASICS tips: Learn easily
Eye catching HTML BASICS tips: Learn easilyEye catching HTML BASICS tips: Learn easily
Eye catching HTML BASICS tips: Learn easilyshabab shihan
 

Tendances (20)

Introduction to HTML
Introduction to HTMLIntroduction to HTML
Introduction to HTML
 
HTML (Web) basics for a beginner
HTML (Web) basics for a beginnerHTML (Web) basics for a beginner
HTML (Web) basics for a beginner
 
HTML, CSS and Java Scripts Basics
HTML, CSS and Java Scripts BasicsHTML, CSS and Java Scripts Basics
HTML, CSS and Java Scripts Basics
 
Html Intro2
Html Intro2Html Intro2
Html Intro2
 
Intro to HTML & CSS
Intro to HTML & CSSIntro to HTML & CSS
Intro to HTML & CSS
 
HTML Semantic Elements
HTML Semantic ElementsHTML Semantic Elements
HTML Semantic Elements
 
Basic HTML
Basic HTMLBasic HTML
Basic HTML
 
Html
HtmlHtml
Html
 
Css ppt
Css pptCss ppt
Css ppt
 
Introduction to HTML5
Introduction to HTML5Introduction to HTML5
Introduction to HTML5
 
Html5 semantics
Html5 semanticsHtml5 semantics
Html5 semantics
 
Html introduction
Html introductionHtml introduction
Html introduction
 
Intro to HTML and CSS basics
Intro to HTML and CSS basicsIntro to HTML and CSS basics
Intro to HTML and CSS basics
 
Cascading Style Sheets (CSS) help
Cascading Style Sheets (CSS) helpCascading Style Sheets (CSS) help
Cascading Style Sheets (CSS) help
 
(Fast) Introduction to HTML & CSS
(Fast) Introduction to HTML & CSS (Fast) Introduction to HTML & CSS
(Fast) Introduction to HTML & CSS
 
Css lecture notes
Css lecture notesCss lecture notes
Css lecture notes
 
Html5 tutorial for beginners
Html5 tutorial for beginnersHtml5 tutorial for beginners
Html5 tutorial for beginners
 
Html 5 tutorial - By Bally Chohan
Html 5 tutorial - By Bally ChohanHtml 5 tutorial - By Bally Chohan
Html 5 tutorial - By Bally Chohan
 
Lecture 2 introduction to html
Lecture 2  introduction to htmlLecture 2  introduction to html
Lecture 2 introduction to html
 
Eye catching HTML BASICS tips: Learn easily
Eye catching HTML BASICS tips: Learn easilyEye catching HTML BASICS tips: Learn easily
Eye catching HTML BASICS tips: Learn easily
 

Similaire à HTML5 Topic 1 (20)

Html tutorial
Html tutorialHtml tutorial
Html tutorial
 
Html tutorial
Html tutorialHtml tutorial
Html tutorial
 
Html tutorial
Html tutorialHtml tutorial
Html tutorial
 
An introduction to html
An introduction to htmlAn introduction to html
An introduction to html
 
Html - Tutorial
Html - TutorialHtml - Tutorial
Html - Tutorial
 
HTML.pptx
HTML.pptxHTML.pptx
HTML.pptx
 
Introduction to HTML
Introduction to HTMLIntroduction to HTML
Introduction to HTML
 
Html presantation
Html presantationHtml presantation
Html presantation
 
Htmlnotes 150323102005-conversion-gate01
Htmlnotes 150323102005-conversion-gate01Htmlnotes 150323102005-conversion-gate01
Htmlnotes 150323102005-conversion-gate01
 
HTML Notes And Some Attributes
HTML Notes And Some AttributesHTML Notes And Some Attributes
HTML Notes And Some Attributes
 
Html basics
Html basicsHtml basics
Html basics
 
Learn html from www
Learn html from wwwLearn html from www
Learn html from www
 
Html5 tutorial
Html5 tutorialHtml5 tutorial
Html5 tutorial
 
Html example
Html exampleHtml example
Html example
 
Html basics NOTE
Html basics NOTEHtml basics NOTE
Html basics NOTE
 
Module 1 - Introduction to HTML.pdf
Module 1 - Introduction to HTML.pdfModule 1 - Introduction to HTML.pdf
Module 1 - Introduction to HTML.pdf
 
Html
HtmlHtml
Html
 
Html basic
Html basicHtml basic
Html basic
 
1. html introduction
1. html introduction1. html introduction
1. html introduction
 
1 introduction to html
1 introduction to html1 introduction to html
1 introduction to html
 

Plus de Juvywen

Chapter 1 Introduction to Media and Information Literacy
Chapter 1 Introduction to Media and Information LiteracyChapter 1 Introduction to Media and Information Literacy
Chapter 1 Introduction to Media and Information LiteracyJuvywen
 
Chapter 2 Understanding Counselling
Chapter 2 Understanding CounsellingChapter 2 Understanding Counselling
Chapter 2 Understanding CounsellingJuvywen
 
Chapter 1 The Social Sciences and the Applied Social Sciences
Chapter 1 The Social Sciences and the Applied Social SciencesChapter 1 The Social Sciences and the Applied Social Sciences
Chapter 1 The Social Sciences and the Applied Social SciencesJuvywen
 
Chapter 2 Study Guide- Understanding Counselling
Chapter 2 Study Guide- Understanding CounsellingChapter 2 Study Guide- Understanding Counselling
Chapter 2 Study Guide- Understanding CounsellingJuvywen
 
HTML 5 Topic 2
HTML 5 Topic 2HTML 5 Topic 2
HTML 5 Topic 2Juvywen
 
Lesson 4 Career Opportunities and Business Ideas in Cooking
Lesson 4 Career Opportunities and Business Ideas in CookingLesson 4 Career Opportunities and Business Ideas in Cooking
Lesson 4 Career Opportunities and Business Ideas in CookingJuvywen
 
Lesson 3 Measuring Tools and Techniques
Lesson 3   Measuring Tools and TechniquesLesson 3   Measuring Tools and Techniques
Lesson 3 Measuring Tools and TechniquesJuvywen
 
Lesson 2 Kitchen and Kitchen Layout
Lesson 2   Kitchen and Kitchen LayoutLesson 2   Kitchen and Kitchen Layout
Lesson 2 Kitchen and Kitchen LayoutJuvywen
 
Lesson 1 Basic Cooking Methods and Food Preparation Techniques
Lesson 1   Basic Cooking Methods and Food Preparation TechniquesLesson 1   Basic Cooking Methods and Food Preparation Techniques
Lesson 1 Basic Cooking Methods and Food Preparation TechniquesJuvywen
 
Lesson 7
Lesson 7Lesson 7
Lesson 7Juvywen
 
Lesson 6
Lesson 6Lesson 6
Lesson 6Juvywen
 
Lesson 1 2 Edited
Lesson 1 2 EditedLesson 1 2 Edited
Lesson 1 2 EditedJuvywen
 
Lesson 5 Manipulating Text, Graphics, and Images
Lesson 5 Manipulating Text, Graphics, and ImagesLesson 5 Manipulating Text, Graphics, and Images
Lesson 5 Manipulating Text, Graphics, and ImagesJuvywen
 
Lesson 4- Developing ict content for specific purposes
Lesson 4- Developing ict content for specific purposesLesson 4- Developing ict content for specific purposes
Lesson 4- Developing ict content for specific purposesJuvywen
 
Lesson 3
Lesson 3Lesson 3
Lesson 3Juvywen
 
LESSON 1, 2 & 3-ETECH 1S
LESSON 1, 2 & 3-ETECH 1SLESSON 1, 2 & 3-ETECH 1S
LESSON 1, 2 & 3-ETECH 1SJuvywen
 

Plus de Juvywen (16)

Chapter 1 Introduction to Media and Information Literacy
Chapter 1 Introduction to Media and Information LiteracyChapter 1 Introduction to Media and Information Literacy
Chapter 1 Introduction to Media and Information Literacy
 
Chapter 2 Understanding Counselling
Chapter 2 Understanding CounsellingChapter 2 Understanding Counselling
Chapter 2 Understanding Counselling
 
Chapter 1 The Social Sciences and the Applied Social Sciences
Chapter 1 The Social Sciences and the Applied Social SciencesChapter 1 The Social Sciences and the Applied Social Sciences
Chapter 1 The Social Sciences and the Applied Social Sciences
 
Chapter 2 Study Guide- Understanding Counselling
Chapter 2 Study Guide- Understanding CounsellingChapter 2 Study Guide- Understanding Counselling
Chapter 2 Study Guide- Understanding Counselling
 
HTML 5 Topic 2
HTML 5 Topic 2HTML 5 Topic 2
HTML 5 Topic 2
 
Lesson 4 Career Opportunities and Business Ideas in Cooking
Lesson 4 Career Opportunities and Business Ideas in CookingLesson 4 Career Opportunities and Business Ideas in Cooking
Lesson 4 Career Opportunities and Business Ideas in Cooking
 
Lesson 3 Measuring Tools and Techniques
Lesson 3   Measuring Tools and TechniquesLesson 3   Measuring Tools and Techniques
Lesson 3 Measuring Tools and Techniques
 
Lesson 2 Kitchen and Kitchen Layout
Lesson 2   Kitchen and Kitchen LayoutLesson 2   Kitchen and Kitchen Layout
Lesson 2 Kitchen and Kitchen Layout
 
Lesson 1 Basic Cooking Methods and Food Preparation Techniques
Lesson 1   Basic Cooking Methods and Food Preparation TechniquesLesson 1   Basic Cooking Methods and Food Preparation Techniques
Lesson 1 Basic Cooking Methods and Food Preparation Techniques
 
Lesson 7
Lesson 7Lesson 7
Lesson 7
 
Lesson 6
Lesson 6Lesson 6
Lesson 6
 
Lesson 1 2 Edited
Lesson 1 2 EditedLesson 1 2 Edited
Lesson 1 2 Edited
 
Lesson 5 Manipulating Text, Graphics, and Images
Lesson 5 Manipulating Text, Graphics, and ImagesLesson 5 Manipulating Text, Graphics, and Images
Lesson 5 Manipulating Text, Graphics, and Images
 
Lesson 4- Developing ict content for specific purposes
Lesson 4- Developing ict content for specific purposesLesson 4- Developing ict content for specific purposes
Lesson 4- Developing ict content for specific purposes
 
Lesson 3
Lesson 3Lesson 3
Lesson 3
 
LESSON 1, 2 & 3-ETECH 1S
LESSON 1, 2 & 3-ETECH 1SLESSON 1, 2 & 3-ETECH 1S
LESSON 1, 2 & 3-ETECH 1S
 

Dernier

Paris 2024 Olympic Geographies - an activity
Paris 2024 Olympic Geographies - an activityParis 2024 Olympic Geographies - an activity
Paris 2024 Olympic Geographies - an activityGeoBlogs
 
Arihant handbook biology for class 11 .pdf
Arihant handbook biology for class 11 .pdfArihant handbook biology for class 11 .pdf
Arihant handbook biology for class 11 .pdfchloefrazer622
 
social pharmacy d-pharm 1st year by Pragati K. Mahajan
social pharmacy d-pharm 1st year by Pragati K. Mahajansocial pharmacy d-pharm 1st year by Pragati K. Mahajan
social pharmacy d-pharm 1st year by Pragati K. Mahajanpragatimahajan3
 
Russian Call Girls in Andheri Airport Mumbai WhatsApp 9167673311 💞 Full Nigh...
Russian Call Girls in Andheri Airport Mumbai WhatsApp  9167673311 💞 Full Nigh...Russian Call Girls in Andheri Airport Mumbai WhatsApp  9167673311 💞 Full Nigh...
Russian Call Girls in Andheri Airport Mumbai WhatsApp 9167673311 💞 Full Nigh...Pooja Nehwal
 
CARE OF CHILD IN INCUBATOR..........pptx
CARE OF CHILD IN INCUBATOR..........pptxCARE OF CHILD IN INCUBATOR..........pptx
CARE OF CHILD IN INCUBATOR..........pptxGaneshChakor2
 
The basics of sentences session 2pptx copy.pptx
The basics of sentences session 2pptx copy.pptxThe basics of sentences session 2pptx copy.pptx
The basics of sentences session 2pptx copy.pptxheathfieldcps1
 
The byproduct of sericulture in different industries.pptx
The byproduct of sericulture in different industries.pptxThe byproduct of sericulture in different industries.pptx
The byproduct of sericulture in different industries.pptxShobhayan Kirtania
 
Measures of Central Tendency: Mean, Median and Mode
Measures of Central Tendency: Mean, Median and ModeMeasures of Central Tendency: Mean, Median and Mode
Measures of Central Tendency: Mean, Median and ModeThiyagu K
 
Sanyam Choudhary Chemistry practical.pdf
Sanyam Choudhary Chemistry practical.pdfSanyam Choudhary Chemistry practical.pdf
Sanyam Choudhary Chemistry practical.pdfsanyamsingh5019
 
JAPAN: ORGANISATION OF PMDA, PHARMACEUTICAL LAWS & REGULATIONS, TYPES OF REGI...
JAPAN: ORGANISATION OF PMDA, PHARMACEUTICAL LAWS & REGULATIONS, TYPES OF REGI...JAPAN: ORGANISATION OF PMDA, PHARMACEUTICAL LAWS & REGULATIONS, TYPES OF REGI...
JAPAN: ORGANISATION OF PMDA, PHARMACEUTICAL LAWS & REGULATIONS, TYPES OF REGI...anjaliyadav012327
 
APM Welcome, APM North West Network Conference, Synergies Across Sectors
APM Welcome, APM North West Network Conference, Synergies Across SectorsAPM Welcome, APM North West Network Conference, Synergies Across Sectors
APM Welcome, APM North West Network Conference, Synergies Across SectorsAssociation for Project Management
 
1029 - Danh muc Sach Giao Khoa 10 . pdf
1029 -  Danh muc Sach Giao Khoa 10 . pdf1029 -  Danh muc Sach Giao Khoa 10 . pdf
1029 - Danh muc Sach Giao Khoa 10 . pdfQucHHunhnh
 
Introduction to Nonprofit Accounting: The Basics
Introduction to Nonprofit Accounting: The BasicsIntroduction to Nonprofit Accounting: The Basics
Introduction to Nonprofit Accounting: The BasicsTechSoup
 
Q4-W6-Restating Informational Text Grade 3
Q4-W6-Restating Informational Text Grade 3Q4-W6-Restating Informational Text Grade 3
Q4-W6-Restating Informational Text Grade 3JemimahLaneBuaron
 
Ecosystem Interactions Class Discussion Presentation in Blue Green Lined Styl...
Ecosystem Interactions Class Discussion Presentation in Blue Green Lined Styl...Ecosystem Interactions Class Discussion Presentation in Blue Green Lined Styl...
Ecosystem Interactions Class Discussion Presentation in Blue Green Lined Styl...fonyou31
 
BASLIQ CURRENT LOOKBOOK LOOKBOOK(1) (1).pdf
BASLIQ CURRENT LOOKBOOK  LOOKBOOK(1) (1).pdfBASLIQ CURRENT LOOKBOOK  LOOKBOOK(1) (1).pdf
BASLIQ CURRENT LOOKBOOK LOOKBOOK(1) (1).pdfSoniaTolstoy
 
Nutritional Needs Presentation - HLTH 104
Nutritional Needs Presentation - HLTH 104Nutritional Needs Presentation - HLTH 104
Nutritional Needs Presentation - HLTH 104misteraugie
 

Dernier (20)

Paris 2024 Olympic Geographies - an activity
Paris 2024 Olympic Geographies - an activityParis 2024 Olympic Geographies - an activity
Paris 2024 Olympic Geographies - an activity
 
Arihant handbook biology for class 11 .pdf
Arihant handbook biology for class 11 .pdfArihant handbook biology for class 11 .pdf
Arihant handbook biology for class 11 .pdf
 
social pharmacy d-pharm 1st year by Pragati K. Mahajan
social pharmacy d-pharm 1st year by Pragati K. Mahajansocial pharmacy d-pharm 1st year by Pragati K. Mahajan
social pharmacy d-pharm 1st year by Pragati K. Mahajan
 
Russian Call Girls in Andheri Airport Mumbai WhatsApp 9167673311 💞 Full Nigh...
Russian Call Girls in Andheri Airport Mumbai WhatsApp  9167673311 💞 Full Nigh...Russian Call Girls in Andheri Airport Mumbai WhatsApp  9167673311 💞 Full Nigh...
Russian Call Girls in Andheri Airport Mumbai WhatsApp 9167673311 💞 Full Nigh...
 
CARE OF CHILD IN INCUBATOR..........pptx
CARE OF CHILD IN INCUBATOR..........pptxCARE OF CHILD IN INCUBATOR..........pptx
CARE OF CHILD IN INCUBATOR..........pptx
 
The basics of sentences session 2pptx copy.pptx
The basics of sentences session 2pptx copy.pptxThe basics of sentences session 2pptx copy.pptx
The basics of sentences session 2pptx copy.pptx
 
The byproduct of sericulture in different industries.pptx
The byproduct of sericulture in different industries.pptxThe byproduct of sericulture in different industries.pptx
The byproduct of sericulture in different industries.pptx
 
Measures of Central Tendency: Mean, Median and Mode
Measures of Central Tendency: Mean, Median and ModeMeasures of Central Tendency: Mean, Median and Mode
Measures of Central Tendency: Mean, Median and Mode
 
Sanyam Choudhary Chemistry practical.pdf
Sanyam Choudhary Chemistry practical.pdfSanyam Choudhary Chemistry practical.pdf
Sanyam Choudhary Chemistry practical.pdf
 
Mattingly "AI & Prompt Design: Structured Data, Assistants, & RAG"
Mattingly "AI & Prompt Design: Structured Data, Assistants, & RAG"Mattingly "AI & Prompt Design: Structured Data, Assistants, & RAG"
Mattingly "AI & Prompt Design: Structured Data, Assistants, & RAG"
 
JAPAN: ORGANISATION OF PMDA, PHARMACEUTICAL LAWS & REGULATIONS, TYPES OF REGI...
JAPAN: ORGANISATION OF PMDA, PHARMACEUTICAL LAWS & REGULATIONS, TYPES OF REGI...JAPAN: ORGANISATION OF PMDA, PHARMACEUTICAL LAWS & REGULATIONS, TYPES OF REGI...
JAPAN: ORGANISATION OF PMDA, PHARMACEUTICAL LAWS & REGULATIONS, TYPES OF REGI...
 
APM Welcome, APM North West Network Conference, Synergies Across Sectors
APM Welcome, APM North West Network Conference, Synergies Across SectorsAPM Welcome, APM North West Network Conference, Synergies Across Sectors
APM Welcome, APM North West Network Conference, Synergies Across Sectors
 
Advance Mobile Application Development class 07
Advance Mobile Application Development class 07Advance Mobile Application Development class 07
Advance Mobile Application Development class 07
 
1029 - Danh muc Sach Giao Khoa 10 . pdf
1029 -  Danh muc Sach Giao Khoa 10 . pdf1029 -  Danh muc Sach Giao Khoa 10 . pdf
1029 - Danh muc Sach Giao Khoa 10 . pdf
 
Introduction to Nonprofit Accounting: The Basics
Introduction to Nonprofit Accounting: The BasicsIntroduction to Nonprofit Accounting: The Basics
Introduction to Nonprofit Accounting: The Basics
 
Q4-W6-Restating Informational Text Grade 3
Q4-W6-Restating Informational Text Grade 3Q4-W6-Restating Informational Text Grade 3
Q4-W6-Restating Informational Text Grade 3
 
Ecosystem Interactions Class Discussion Presentation in Blue Green Lined Styl...
Ecosystem Interactions Class Discussion Presentation in Blue Green Lined Styl...Ecosystem Interactions Class Discussion Presentation in Blue Green Lined Styl...
Ecosystem Interactions Class Discussion Presentation in Blue Green Lined Styl...
 
BASLIQ CURRENT LOOKBOOK LOOKBOOK(1) (1).pdf
BASLIQ CURRENT LOOKBOOK  LOOKBOOK(1) (1).pdfBASLIQ CURRENT LOOKBOOK  LOOKBOOK(1) (1).pdf
BASLIQ CURRENT LOOKBOOK LOOKBOOK(1) (1).pdf
 
Mattingly "AI & Prompt Design: The Basics of Prompt Design"
Mattingly "AI & Prompt Design: The Basics of Prompt Design"Mattingly "AI & Prompt Design: The Basics of Prompt Design"
Mattingly "AI & Prompt Design: The Basics of Prompt Design"
 
Nutritional Needs Presentation - HLTH 104
Nutritional Needs Presentation - HLTH 104Nutritional Needs Presentation - HLTH 104
Nutritional Needs Presentation - HLTH 104
 

HTML5 Topic 1

  • 2.  TOPICS: HTML Introduction HTML Editors HTML Basics HTML Elements
  • 3. What is HTML?  HTML is the standard markup language for creating Web pages.  HTML stands for Hyper Text Markup Language  HTML describes the structure of Web pages using markup  HTML elements are the building blocks of HTML pages
  • 4.  HTML elements are represented by tags.  HTML tags label pieces of content such as "heading", "paragraph", "table", and so on.  Browsers do not display the HTML tags, but use them to render the content of the page.
  • 5. A Simple HTML Document <!DOCTYPE html> <html> <head> <title>Page Title</title> </head> <body> <h1>My First Heading</h1> <p>My first paragraph.</p> </body> </html>
  • 6. Example Explained •The <!DOCTYPE html> declaration defines this document to be HTML5 •The <html> element is the root element of an HTML page •The <head> element contains meta information about the document •The <title> element specifies a title for the document •The <body> element contains the visible page content •The <h1> element defines a large heading •The <p> element defines a paragraph
  • 7. HTML Tags HTML tags are element names surrounded by angle brackets: <tagname>content goes here...</tagname>  HTML tags normally come in pairs like <p> and </p>  The first tag in a pair is the start tag, the second tag is the end tag  The end tag is written like the start tag, but with a forward slash inserted before the tag name Tip: The start tag is also called the opening tag, and the end tag the closing tag
  • 8. Web Browsers  The purpose of a web browser (Chrome, IE, Firefox, Safari) is to read HTML documents and display them.  The browser does not display the HTML tags, but uses them to determine how to display the document.
  • 9.
  • 10. HTML Page Structure Below is a visualization of an HTML page structure: Note: Only the content inside the <body> section (the white area above) is displayed in a browser.
  • 11. The <!DOCTYPE> Declaration  The <!DOCTYPE> declaration represents the document type, and helps browsers to display web pages correctly.  It must only appear once, at the top of the page (before any HTML tags).  The <!DOCTYPE> declaration is not case sensitive.  The <!DOCTYPE> declaration for HTML5 is: <!DOCTYPE html>
  • 13. HTML Editors Write HTML Using Notepad or TextEdit  Web pages can be created and modified by using professional HTML editors.  However, for learning HTML we recommend a simple text editor like Notepad (PC) or TextEdit (Mac).  We believe using a simple text editor is a good way to learn HTML.  Follow the four steps below to create your first web page with Notepad or TextEdit.
  • 14. Step 1: Open Notepad (PC)  Windows 8 or later:  Open the Start Screen (the window symbol at the bottom left on your screen). Type Notepad.  Windows 7 or earlier:  Open Start > Programs > Accessories > Notepad
  • 15. Step 1: Open TextEdit (Mac)  Open Finder > Applications > TextEdit  Also change some preferences to get the application to save files correctly. In Preferences > Format > choose "Plain Text"  Then under "Open and Save", check the box that says "Ignore rich text commands in HTML files".  Then open a new document to place the code.
  • 16. Step 2: Write Some HTML  Write or copy some HTML into Notepad.
  • 17.
  • 18. Step 3: Save the HTML Page  Save the file on your computer. Select File > Save as in the Notepad menu.  Name the file "index.htm" and set the encoding to UTF- 8 (which is the preferred encoding for HTML files).
  • 19. You can use either .htm or .html as file extension. There is no difference, it is up to you.
  • 20. Step 4: View the HTML Page in Your Browser  Open the saved HTML file in your favorite browser (double click on the file, or right-click - and choose "Open with").  The result will look much like this:
  • 21. HTML Basic HTML Documents  All HTML documents must start with a document type declaration: <!DOCTYPE html>.  The HTML document itself begins with <html> and ends with </html>.  The visible part of the HTML document is between <body> and </body>.
  • 22.
  • 23. HTML Headings  HTML headings are defined with the <h1> to <h6> tags.  <h1> defines the most important heading. <h6> defines the least important heading:
  • 24. HTML Paragraphs  HTML paragraphs are defined with the <p> tag:
  • 25. HTML Links  HTML links are defined with the <a> tag: The link's destination is specified in the href attribute. Attributes are used to provide additional information about HTML elements.
  • 26.
  • 27. HTML Images  HTML images are defined with the <img> tag.  The source file (src), alternative text (alt), width, and height are provided as attributes:
  • 28.
  • 29. HTML Elements  An HTML element usually consists of a start tag and end tag, with the content inserted in between: <tagname>Content goes here...</tagname>  The HTML element is everything from the start tag to the end tag: <p>My first paragraph.</p>
  • 30. HTML elements with no content are called empty elements. Empty elements do not have an end tag, such as the <br> element (which indicates a line break).
  • 31. Nested HTML Elements  HTML elements can be nested (elements can contain elements).  All HTML documents consist of nested HTML elements.
  • 32.
  • 33. Example Explained  The <html> element defines the whole document.  It has a start tag <html> and an end tag </html>.  The element content is another HTML element (the <body> element).
  • 34.  The <body> element defines the document body.  It has a start tag <body> and an end tag </body>.  The element content is two other HTML elements (<h1> and <p>).
  • 35.  The <h1> element defines a heading.  It has a start tag <h1> and an end tag </h1>.  The element content is: My First Heading.
  • 36.  The <p> element defines a paragraph.  It has a start tag <p> and an end tag </p>.  The element content is: My first paragraph.
  • 37. Do Not Forget the End Tag  Some HTML elements will display correctly, even if you forget the end tag:
  • 38. Empty HTML Elements  HTML elements with no content are called empty elements.  <br> is an empty element without a closing tag (the <br> tag defines a line break).  Empty elements can be "closed" in the opening tag like this: <br />.  HTML5 does not require empty elements to be closed. But if you want stricter validation, or if you need to make your document readable by XML parsers, you must close all HTML elements properly.
  • 39. Use Lowercase Tags  HTML tags are not case sensitive: <P> means the same as <p>.  The HTML5 standard does not require lowercase tags, but W3C recommends lowercase in HTML, and demands lowercase for stricter document types like XHTML.
  • 40. -END-

Notes de l'éditeur

  1. HTML5 Tutorial With HTML you can create your own Web site.
  2. "Markup language" refers to the way tags are used to define the page layout and elements within the page. Markup-structure
  3. Metadata is data (information) about data. The <meta> tag provides metadata about the HTMLdocument. Metadata will not be displayed on the page, but will be machine parsable. Meta elements are typically used to specify page description, keywords, author of the document, last modified, and other metadata.
  4. Definition of: HREF. HREF. (Hypertext REFerence) The HTML code used to create a link to another page. The HREF is an attribute of the anchor tag, which is also used to identify sections within a document.
  5. An HTML attribute is a modifier of an HTML element type. An attribute either modifies the default functionality of an element type or provides functionality to certain element types unable to function correctly without them. In HTML syntax, anattribute is added to an HTML start tag. src and srcset. New in HTML5 is an image attribute named srcset . This attribute is used to define a list of image source files, along with sizing information, so that the browser can select the most appropriate option. When the srcset attribute is set, thesrc files will be used as a “fallback” or “default” image. Alt text (alternative text) is a word or phrase that can be inserted as an attribute in an HTML (Hypertext Markup Language) document to tell Web site viewers the nature or contents of an image. ... An alt attribute starts out with the character sequence alt= and then contains the alt text within quotation marks.
  6. Chapter Summary Use the HTML <img> element to define an image. Use the HTML src attribute to define the URL of the image. Use the HTML alt attribute to define an alternate text for an image, if it cannot be displayed. Use the HTML width and height attributes to define the size of the image.
  7. An HTML element is an individual component of an HTML document or web page, once this has been parsed into the Document Object Model. HTML is composed of a tree of HTML nodes, such as text nodes. Each node can have HTML attributes specified.
  8. This example contains four HTML elements:
  9. According to the XML DOM, everything in an XML document is a node: The entire document is a document node. Every XML element is an elementnode. The text in the XML elements are text nodes. Every attribute is an attribute node. -The example above works in all browsers, because the closing tag is considered optional. Never rely on this. It might produce unexpected results and/or errors if you forget the end tag.