SlideShare a Scribd company logo
1 of 59
HTML
Source: https://www.w3schools.com/html/default.asp
Prepared by: Engr. Juvywen M. Pollentes
TOPICS:
HTML Attributes
HTML Headings
HTML Paragraphs
HTML Styles
HTML Attributes
 Attributes provide additional information about HTML
elements.
 All HTML elements can have attributes
 Attributes provide additional information about an element
 Attributes are always specified in the start tag
 Attributes usually come in name/value pairs
like: name="value"
The href Attribute
 HTML links are defined with the <a> tag. The link address is
specified in the href attribute:
The src Attribute
 HTML images are defined with the <img> tag.
 The filename of the image source is specified in
the src attribute:
The width and height Attributes
 The image size is specified in pixels: width="500"
means 500 pixels wide.
The alt Attribute
 The alt attribute specifies an alternative text to be used, when
an image cannot be displayed.
 The alt attribute is also useful if the image does not exist:
The style Attribute
 The style attribute is used to specify the styling of an element,
like color, font, size etc
The lang Attribute
 The language of the document can be
declared in the <html> tag.
 The language is declared with
the lang attribute.
 Declaring a language is important for
accessibility applications (screen
readers) and search engines:
 The first two letters specify the
language (en). If there is a dialect, use
two more letters (US).
The title Attribute
 A title attribute is added to the <p> element. The value of the
title attribute will be displayed as a tooltip when you mouse
over the paragraph:
We Suggest: Use Lowercase Attributes
 The HTML5 standard does not require lowercase attribute
names.
 The title attribute can be written with uppercase or lowercase
like title or TITLE.
 W3C recommends lowercase in HTML,
and demands lowercase for stricter document types like
XHTML.
We Suggest: Quote Attribute Values
 The HTML5 standard does not require quotes around
attribute values.
 The href attribute, demonstrated above, can be
written as:
 Using quotes are the most common. Omitting quotes
can produce errors.
Single or Double Quotes?
 Double quotes around attribute values are the most
common in HTML, but single quotes can also be used.
 In some situations, when the attribute value itself
contains double quotes, it is necessary to use single
quotes:
HTML Headings
 Headings are defined with the <h1> to <h6> tags.
 <h1> defines the most important heading. <h6> defines the
least important heading.
 Note: Browsers automatically add some white space (a
margin) before and after a heading.
Headings Are Important
 Search engines use the headings to index the structure and
content of your web pages.
 Users skim your pages by its headings. It is important to use
headings to show the document structure.
 <h1> headings should be used for main headings, followed by
<h2> headings, then the less important <h3>, and so on.
 Note: Use HTML headings for headings only. Don't use
headings to make text BIG or bold.
Bigger Headings
 Each HTML heading has a default size. However, you can
specify the size for any heading with the style attribute:
HTML Horizontal Rules
 The <hr> tag defines a thematic break in an HTML page, and
is most often displayed as a horizontal rule.
 The <hr> element is used to separate content (or define a
change) in an HTML page:
The HTML <head> Element
 The HTML <head> element has nothing to do with HTML
headings.
 The <head> element is a container for metadata. HTML
metadata is data about the HTML document. Metadata is not
displayed.
 The <head> element is placed between the <html> tag and
the <body> tag:
 Note: Metadata typically define the document title, character
set, styles, links, scripts, and other meta information.
How to View HTML Source?
View HTML Source Code:
 To find out, right-click in the page and select "View Page
Source" (in Chrome) or "View Source" (in IE), or similar in
other browsers. This will open a window containing the HTML
source code of the page.
 Inspect an HTML Element:
 Right-click on an element (or a blank area), and choose
"Inspect" or "Inspect Element" to see what elements are
made up of (you will see both the HTML and the CSS). You
can also edit the HTML or CSS on-the-fly in the Elements or
Styles panel that opens.
HTML Paragraphs
 The HTML <p> element defines a paragraph:
 Note: Browsers automatically add some white
space (a margin) before and after a paragraph.
HTML Display
 You cannot be sure how HTML will be displayed.
 Large or small screens, and resized windows will create
different results.
 With HTML, you cannot change the output by adding extra
spaces or extra lines in your HTML code.
 The browser will remove any extra spaces and extra lines
when the page is displayed.
Don't Forget the End Tag
 Most browsers will display HTML correctly even if
you forget the end tag:
 Note: Dropping the end tag can produce
unexpected results or errors.
HTML Line Breaks
 The HTML <br> element defines a line break.
 Use <br> if you want a line break (a new line)
without starting a new paragraph:
 The <br> tag is an empty tag, which means that it
has no end tag.
The HTML <pre> Element
 The HTML <pre> element defines preformatted
text.
 The text inside a <pre> element is displayed in a
fixed-width font (usually Courier), and it preserves
both spaces and line breaks:
HTML Styles
The HTML Style Attribute
 Setting the style of an HTML element, can be done with
the style attribute.
 The HTML style attribute has the following syntax:
<tagname style="property:value;">
 The property is a CSS property. The value is a CSS value.
You will learn more about CSS later in this tutorial.
HTML Background Color
 The background-color property defines the background
color for an HTML element.
 This example sets the background color for a page to
powderblue:
HTML Text Color
 The color property defines the text color for an HTML
element:
HTML Fonts
 The font-family property defines the font to be used
for an HTML element:
HTML Text Size
 The font-size property defines the text size for an HTML
element:
HTML Text Alignment
 The text-align property defines the horizontal text
alignment for an HTML element:
Chapter Summary
 Use the style attribute for styling HTML elements
 Use background-color for background color
 Use color for text colors
 Use font-family for text fonts
 Use font-size for text sizes
 Use text-align for text alignment

More Related Content

What's hot

Web Application and HTML Summary
Web Application and HTML SummaryWeb Application and HTML Summary
Web Application and HTML SummaryFernando Torres
 
Computer fundamentals-internet p2
Computer fundamentals-internet p2Computer fundamentals-internet p2
Computer fundamentals-internet p2Leo Mark Villar
 
WEB PAGE DESIGN USING HTML
WEB PAGE DESIGN USING HTMLWEB PAGE DESIGN USING HTML
WEB PAGE DESIGN USING HTMLSneha Mukherjee
 
What is html xml and xhtml
What is html xml and xhtmlWhat is html xml and xhtml
What is html xml and xhtmlFkdiMl
 
CSS Comprehensive Overview
CSS Comprehensive OverviewCSS Comprehensive Overview
CSS Comprehensive OverviewMohamed Loey
 
Vskills certified html designer Notes
Vskills certified html designer NotesVskills certified html designer Notes
Vskills certified html designer NotesVskills
 
Introduction to HTML
Introduction to HTMLIntroduction to HTML
Introduction to HTMLyht4ever
 
Practical file on web technology(html)
Practical file on web technology(html)Practical file on web technology(html)
Practical file on web technology(html)RAJWANT KAUR
 
Introduction to HTML
Introduction to HTMLIntroduction to HTML
Introduction to HTMLMayaLisa
 
Hyper text markup Language
Hyper text markup LanguageHyper text markup Language
Hyper text markup LanguageNaveeth Babu
 
Web technology practical list
Web technology practical listWeb technology practical list
Web technology practical listdesaipratu10
 
Introduction to HTML
Introduction to HTMLIntroduction to HTML
Introduction to HTMLAmeer Khan
 

What's hot (20)

Web Application and HTML Summary
Web Application and HTML SummaryWeb Application and HTML Summary
Web Application and HTML Summary
 
Computer fundamentals-internet p2
Computer fundamentals-internet p2Computer fundamentals-internet p2
Computer fundamentals-internet p2
 
Xhtml
XhtmlXhtml
Xhtml
 
WEB PAGE DESIGN USING HTML
WEB PAGE DESIGN USING HTMLWEB PAGE DESIGN USING HTML
WEB PAGE DESIGN USING HTML
 
Html Tutorial
Html Tutorial Html Tutorial
Html Tutorial
 
HTML
HTMLHTML
HTML
 
Session4
Session4Session4
Session4
 
What is html xml and xhtml
What is html xml and xhtmlWhat is html xml and xhtml
What is html xml and xhtml
 
CSS Comprehensive Overview
CSS Comprehensive OverviewCSS Comprehensive Overview
CSS Comprehensive Overview
 
Vskills certified html designer Notes
Vskills certified html designer NotesVskills certified html designer Notes
Vskills certified html designer Notes
 
Introduction to HTML
Introduction to HTMLIntroduction to HTML
Introduction to HTML
 
Practical file on web technology(html)
Practical file on web technology(html)Practical file on web technology(html)
Practical file on web technology(html)
 
Xhtml
XhtmlXhtml
Xhtml
 
Introduction to HTML
Introduction to HTMLIntroduction to HTML
Introduction to HTML
 
Tags in html
Tags in htmlTags in html
Tags in html
 
Introduction to XHTML
Introduction to XHTMLIntroduction to XHTML
Introduction to XHTML
 
Hyper text markup Language
Hyper text markup LanguageHyper text markup Language
Hyper text markup Language
 
Web technology practical list
Web technology practical listWeb technology practical list
Web technology practical list
 
HTML Basics by software development company india
HTML Basics by software development company indiaHTML Basics by software development company india
HTML Basics by software development company india
 
Introduction to HTML
Introduction to HTMLIntroduction to HTML
Introduction to HTML
 

Similar to HTML 5 Topic 2 (20)

HTML Training Part1
HTML Training Part1HTML Training Part1
HTML Training Part1
 
Html
HtmlHtml
Html
 
Html & Html5 from scratch
Html & Html5 from scratchHtml & Html5 from scratch
Html & Html5 from scratch
 
Html Workshop
Html WorkshopHtml Workshop
Html Workshop
 
Html basics
Html basicsHtml basics
Html basics
 
web development.pdf
web development.pdfweb development.pdf
web development.pdf
 
Web Development 1 (HTML & CSS)
Web Development 1 (HTML & CSS)Web Development 1 (HTML & CSS)
Web Development 1 (HTML & CSS)
 
Html
HtmlHtml
Html
 
Html
HtmlHtml
Html
 
HTML.pptx
HTML.pptxHTML.pptx
HTML.pptx
 
Higher Computing Science HTML
Higher Computing Science HTMLHigher Computing Science HTML
Higher Computing Science HTML
 
Html tutorial
Html tutorialHtml tutorial
Html tutorial
 
Html basics
Html basicsHtml basics
Html basics
 
Html
HtmlHtml
Html
 
Webithon Workshop
Webithon WorkshopWebithon Workshop
Webithon Workshop
 
Web Development 3 (HTML & CSS)
Web Development 3  (HTML & CSS)Web Development 3  (HTML & CSS)
Web Development 3 (HTML & CSS)
 
Html
HtmlHtml
Html
 
HTML - part 1
HTML - part 1HTML - part 1
HTML - part 1
 
Html presentation
Html presentationHtml presentation
Html presentation
 
Html notes
Html notesHtml notes
Html notes
 

More from 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
 
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
 

More from Juvywen (15)

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
 
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
 

Recently uploaded

How to Configure Email Server in Odoo 17
How to Configure Email Server in Odoo 17How to Configure Email Server in Odoo 17
How to Configure Email Server in Odoo 17Celine George
 
Hybridoma Technology ( Production , Purification , and Application )
Hybridoma Technology  ( Production , Purification , and Application  ) Hybridoma Technology  ( Production , Purification , and Application  )
Hybridoma Technology ( Production , Purification , and Application ) Sakshi Ghasle
 
call girls in Kamla Market (DELHI) 🔝 >༒9953330565🔝 genuine Escort Service 🔝✔️✔️
call girls in Kamla Market (DELHI) 🔝 >༒9953330565🔝 genuine Escort Service 🔝✔️✔️call girls in Kamla Market (DELHI) 🔝 >༒9953330565🔝 genuine Escort Service 🔝✔️✔️
call girls in Kamla Market (DELHI) 🔝 >༒9953330565🔝 genuine Escort Service 🔝✔️✔️9953056974 Low Rate Call Girls In Saket, Delhi NCR
 
Contemporary philippine arts from the regions_PPT_Module_12 [Autosaved] (1).pptx
Contemporary philippine arts from the regions_PPT_Module_12 [Autosaved] (1).pptxContemporary philippine arts from the regions_PPT_Module_12 [Autosaved] (1).pptx
Contemporary philippine arts from the regions_PPT_Module_12 [Autosaved] (1).pptxRoyAbrique
 
_Math 4-Q4 Week 5.pptx Steps in Collecting Data
_Math 4-Q4 Week 5.pptx Steps in Collecting Data_Math 4-Q4 Week 5.pptx Steps in Collecting Data
_Math 4-Q4 Week 5.pptx Steps in Collecting DataJhengPantaleon
 
KSHARA STURA .pptx---KSHARA KARMA THERAPY (CAUSTIC THERAPY)————IMP.OF KSHARA ...
KSHARA STURA .pptx---KSHARA KARMA THERAPY (CAUSTIC THERAPY)————IMP.OF KSHARA ...KSHARA STURA .pptx---KSHARA KARMA THERAPY (CAUSTIC THERAPY)————IMP.OF KSHARA ...
KSHARA STURA .pptx---KSHARA KARMA THERAPY (CAUSTIC THERAPY)————IMP.OF KSHARA ...M56BOOKSTORE PRODUCT/SERVICE
 
URLs and Routing in the Odoo 17 Website App
URLs and Routing in the Odoo 17 Website AppURLs and Routing in the Odoo 17 Website App
URLs and Routing in the Odoo 17 Website AppCeline George
 
Software Engineering Methodologies (overview)
Software Engineering Methodologies (overview)Software Engineering Methodologies (overview)
Software Engineering Methodologies (overview)eniolaolutunde
 
Paris 2024 Olympic Geographies - an activity
Paris 2024 Olympic Geographies - an activityParis 2024 Olympic Geographies - an activity
Paris 2024 Olympic Geographies - an activityGeoBlogs
 
A Critique of the Proposed National Education Policy Reform
A Critique of the Proposed National Education Policy ReformA Critique of the Proposed National Education Policy Reform
A Critique of the Proposed National Education Policy ReformChameera Dedduwage
 
Class 11 Legal Studies Ch-1 Concept of State .pdf
Class 11 Legal Studies Ch-1 Concept of State .pdfClass 11 Legal Studies Ch-1 Concept of State .pdf
Class 11 Legal Studies Ch-1 Concept of State .pdfakmcokerachita
 
Presiding Officer Training module 2024 lok sabha elections
Presiding Officer Training module 2024 lok sabha electionsPresiding Officer Training module 2024 lok sabha elections
Presiding Officer Training module 2024 lok sabha electionsanshu789521
 
Sanyam Choudhary Chemistry practical.pdf
Sanyam Choudhary Chemistry practical.pdfSanyam Choudhary Chemistry practical.pdf
Sanyam Choudhary Chemistry practical.pdfsanyamsingh5019
 
Accessible design: Minimum effort, maximum impact
Accessible design: Minimum effort, maximum impactAccessible design: Minimum effort, maximum impact
Accessible design: Minimum effort, maximum impactdawncurless
 
18-04-UA_REPORT_MEDIALITERAСY_INDEX-DM_23-1-final-eng.pdf
18-04-UA_REPORT_MEDIALITERAСY_INDEX-DM_23-1-final-eng.pdf18-04-UA_REPORT_MEDIALITERAСY_INDEX-DM_23-1-final-eng.pdf
18-04-UA_REPORT_MEDIALITERAСY_INDEX-DM_23-1-final-eng.pdfssuser54595a
 
Alper Gobel In Media Res Media Component
Alper Gobel In Media Res Media ComponentAlper Gobel In Media Res Media Component
Alper Gobel In Media Res Media ComponentInMediaRes1
 
Organic Name Reactions for the students and aspirants of Chemistry12th.pptx
Organic Name Reactions  for the students and aspirants of Chemistry12th.pptxOrganic Name Reactions  for the students and aspirants of Chemistry12th.pptx
Organic Name Reactions for the students and aspirants of Chemistry12th.pptxVS Mahajan Coaching Centre
 

Recently uploaded (20)

How to Configure Email Server in Odoo 17
How to Configure Email Server in Odoo 17How to Configure Email Server in Odoo 17
How to Configure Email Server in Odoo 17
 
Hybridoma Technology ( Production , Purification , and Application )
Hybridoma Technology  ( Production , Purification , and Application  ) Hybridoma Technology  ( Production , Purification , and Application  )
Hybridoma Technology ( Production , Purification , and Application )
 
call girls in Kamla Market (DELHI) 🔝 >༒9953330565🔝 genuine Escort Service 🔝✔️✔️
call girls in Kamla Market (DELHI) 🔝 >༒9953330565🔝 genuine Escort Service 🔝✔️✔️call girls in Kamla Market (DELHI) 🔝 >༒9953330565🔝 genuine Escort Service 🔝✔️✔️
call girls in Kamla Market (DELHI) 🔝 >༒9953330565🔝 genuine Escort Service 🔝✔️✔️
 
Contemporary philippine arts from the regions_PPT_Module_12 [Autosaved] (1).pptx
Contemporary philippine arts from the regions_PPT_Module_12 [Autosaved] (1).pptxContemporary philippine arts from the regions_PPT_Module_12 [Autosaved] (1).pptx
Contemporary philippine arts from the regions_PPT_Module_12 [Autosaved] (1).pptx
 
_Math 4-Q4 Week 5.pptx Steps in Collecting Data
_Math 4-Q4 Week 5.pptx Steps in Collecting Data_Math 4-Q4 Week 5.pptx Steps in Collecting Data
_Math 4-Q4 Week 5.pptx Steps in Collecting Data
 
KSHARA STURA .pptx---KSHARA KARMA THERAPY (CAUSTIC THERAPY)————IMP.OF KSHARA ...
KSHARA STURA .pptx---KSHARA KARMA THERAPY (CAUSTIC THERAPY)————IMP.OF KSHARA ...KSHARA STURA .pptx---KSHARA KARMA THERAPY (CAUSTIC THERAPY)————IMP.OF KSHARA ...
KSHARA STURA .pptx---KSHARA KARMA THERAPY (CAUSTIC THERAPY)————IMP.OF KSHARA ...
 
URLs and Routing in the Odoo 17 Website App
URLs and Routing in the Odoo 17 Website AppURLs and Routing in the Odoo 17 Website App
URLs and Routing in the Odoo 17 Website App
 
Software Engineering Methodologies (overview)
Software Engineering Methodologies (overview)Software Engineering Methodologies (overview)
Software Engineering Methodologies (overview)
 
Paris 2024 Olympic Geographies - an activity
Paris 2024 Olympic Geographies - an activityParis 2024 Olympic Geographies - an activity
Paris 2024 Olympic Geographies - an activity
 
A Critique of the Proposed National Education Policy Reform
A Critique of the Proposed National Education Policy ReformA Critique of the Proposed National Education Policy Reform
A Critique of the Proposed National Education Policy Reform
 
Class 11 Legal Studies Ch-1 Concept of State .pdf
Class 11 Legal Studies Ch-1 Concept of State .pdfClass 11 Legal Studies Ch-1 Concept of State .pdf
Class 11 Legal Studies Ch-1 Concept of State .pdf
 
Presiding Officer Training module 2024 lok sabha elections
Presiding Officer Training module 2024 lok sabha electionsPresiding Officer Training module 2024 lok sabha elections
Presiding Officer Training module 2024 lok sabha elections
 
9953330565 Low Rate Call Girls In Rohini Delhi NCR
9953330565 Low Rate Call Girls In Rohini  Delhi NCR9953330565 Low Rate Call Girls In Rohini  Delhi NCR
9953330565 Low Rate Call Girls In Rohini Delhi NCR
 
Model Call Girl in Bikash Puri Delhi reach out to us at 🔝9953056974🔝
Model Call Girl in Bikash Puri  Delhi reach out to us at 🔝9953056974🔝Model Call Girl in Bikash Puri  Delhi reach out to us at 🔝9953056974🔝
Model Call Girl in Bikash Puri Delhi reach out to us at 🔝9953056974🔝
 
Sanyam Choudhary Chemistry practical.pdf
Sanyam Choudhary Chemistry practical.pdfSanyam Choudhary Chemistry practical.pdf
Sanyam Choudhary Chemistry practical.pdf
 
Accessible design: Minimum effort, maximum impact
Accessible design: Minimum effort, maximum impactAccessible design: Minimum effort, maximum impact
Accessible design: Minimum effort, maximum impact
 
18-04-UA_REPORT_MEDIALITERAСY_INDEX-DM_23-1-final-eng.pdf
18-04-UA_REPORT_MEDIALITERAСY_INDEX-DM_23-1-final-eng.pdf18-04-UA_REPORT_MEDIALITERAСY_INDEX-DM_23-1-final-eng.pdf
18-04-UA_REPORT_MEDIALITERAСY_INDEX-DM_23-1-final-eng.pdf
 
Alper Gobel In Media Res Media Component
Alper Gobel In Media Res Media ComponentAlper Gobel In Media Res Media Component
Alper Gobel In Media Res Media Component
 
Organic Name Reactions for the students and aspirants of Chemistry12th.pptx
Organic Name Reactions  for the students and aspirants of Chemistry12th.pptxOrganic Name Reactions  for the students and aspirants of Chemistry12th.pptx
Organic Name Reactions for the students and aspirants of Chemistry12th.pptx
 
TataKelola dan KamSiber Kecerdasan Buatan v022.pdf
TataKelola dan KamSiber Kecerdasan Buatan v022.pdfTataKelola dan KamSiber Kecerdasan Buatan v022.pdf
TataKelola dan KamSiber Kecerdasan Buatan v022.pdf
 

HTML 5 Topic 2

  • 4.  Attributes provide additional information about HTML elements.  All HTML elements can have attributes  Attributes provide additional information about an element  Attributes are always specified in the start tag  Attributes usually come in name/value pairs like: name="value"
  • 5. The href Attribute  HTML links are defined with the <a> tag. The link address is specified in the href attribute:
  • 6. The src Attribute  HTML images are defined with the <img> tag.  The filename of the image source is specified in the src attribute:
  • 7. The width and height Attributes  The image size is specified in pixels: width="500" means 500 pixels wide.
  • 8. The alt Attribute  The alt attribute specifies an alternative text to be used, when an image cannot be displayed.
  • 9.  The alt attribute is also useful if the image does not exist:
  • 10. The style Attribute  The style attribute is used to specify the styling of an element, like color, font, size etc
  • 11. The lang Attribute  The language of the document can be declared in the <html> tag.  The language is declared with the lang attribute.  Declaring a language is important for accessibility applications (screen readers) and search engines:  The first two letters specify the language (en). If there is a dialect, use two more letters (US).
  • 12. The title Attribute  A title attribute is added to the <p> element. The value of the title attribute will be displayed as a tooltip when you mouse over the paragraph:
  • 13. We Suggest: Use Lowercase Attributes  The HTML5 standard does not require lowercase attribute names.  The title attribute can be written with uppercase or lowercase like title or TITLE.  W3C recommends lowercase in HTML, and demands lowercase for stricter document types like XHTML.
  • 14. We Suggest: Quote Attribute Values  The HTML5 standard does not require quotes around attribute values.  The href attribute, demonstrated above, can be written as:  Using quotes are the most common. Omitting quotes can produce errors.
  • 15. Single or Double Quotes?  Double quotes around attribute values are the most common in HTML, but single quotes can also be used.  In some situations, when the attribute value itself contains double quotes, it is necessary to use single quotes:
  • 16.
  • 18.
  • 19.  Headings are defined with the <h1> to <h6> tags.  <h1> defines the most important heading. <h6> defines the least important heading.  Note: Browsers automatically add some white space (a margin) before and after a heading.
  • 20. Headings Are Important  Search engines use the headings to index the structure and content of your web pages.  Users skim your pages by its headings. It is important to use headings to show the document structure.  <h1> headings should be used for main headings, followed by <h2> headings, then the less important <h3>, and so on.  Note: Use HTML headings for headings only. Don't use headings to make text BIG or bold.
  • 21. Bigger Headings  Each HTML heading has a default size. However, you can specify the size for any heading with the style attribute:
  • 22. HTML Horizontal Rules  The <hr> tag defines a thematic break in an HTML page, and is most often displayed as a horizontal rule.  The <hr> element is used to separate content (or define a change) in an HTML page:
  • 23.
  • 24. The HTML <head> Element  The HTML <head> element has nothing to do with HTML headings.  The <head> element is a container for metadata. HTML metadata is data about the HTML document. Metadata is not displayed.  The <head> element is placed between the <html> tag and the <body> tag:
  • 25.  Note: Metadata typically define the document title, character set, styles, links, scripts, and other meta information.
  • 26. How to View HTML Source? View HTML Source Code:  To find out, right-click in the page and select "View Page Source" (in Chrome) or "View Source" (in IE), or similar in other browsers. This will open a window containing the HTML source code of the page.
  • 27.
  • 28.
  • 29.  Inspect an HTML Element:  Right-click on an element (or a blank area), and choose "Inspect" or "Inspect Element" to see what elements are made up of (you will see both the HTML and the CSS). You can also edit the HTML or CSS on-the-fly in the Elements or Styles panel that opens.
  • 30.
  • 31.
  • 32.
  • 34.  The HTML <p> element defines a paragraph:  Note: Browsers automatically add some white space (a margin) before and after a paragraph.
  • 35. HTML Display  You cannot be sure how HTML will be displayed.  Large or small screens, and resized windows will create different results.  With HTML, you cannot change the output by adding extra spaces or extra lines in your HTML code.  The browser will remove any extra spaces and extra lines when the page is displayed.
  • 36.
  • 37.
  • 38. Don't Forget the End Tag  Most browsers will display HTML correctly even if you forget the end tag:  Note: Dropping the end tag can produce unexpected results or errors.
  • 39. HTML Line Breaks  The HTML <br> element defines a line break.  Use <br> if you want a line break (a new line) without starting a new paragraph:  The <br> tag is an empty tag, which means that it has no end tag.
  • 40.
  • 41.
  • 42. The HTML <pre> Element  The HTML <pre> element defines preformatted text.  The text inside a <pre> element is displayed in a fixed-width font (usually Courier), and it preserves both spaces and line breaks:
  • 43.
  • 44.
  • 46.
  • 47.
  • 48. The HTML Style Attribute  Setting the style of an HTML element, can be done with the style attribute.  The HTML style attribute has the following syntax: <tagname style="property:value;">  The property is a CSS property. The value is a CSS value. You will learn more about CSS later in this tutorial.
  • 49. HTML Background Color  The background-color property defines the background color for an HTML element.  This example sets the background color for a page to powderblue:
  • 50.
  • 51. HTML Text Color  The color property defines the text color for an HTML element:
  • 52.
  • 53. HTML Fonts  The font-family property defines the font to be used for an HTML element:
  • 54.
  • 55. HTML Text Size  The font-size property defines the text size for an HTML element:
  • 56.
  • 57. HTML Text Alignment  The text-align property defines the horizontal text alignment for an HTML element:
  • 58.
  • 59. Chapter Summary  Use the style attribute for styling HTML elements  Use background-color for background color  Use color for text colors  Use font-family for text fonts  Use font-size for text sizes  Use text-align for text alignment

Editor's Notes

  1. HTML5 Tutorial With HTML you can create your own Web site.
  2.  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.
  3. Attribute-characteristics, qulity, feature
  4. Index-guide Skim-glance
  5. Have you ever seen a Web page and wondered "Hey! How did they do that?"
  6. <h1 style = "color:blue; font-size:1000%;"> This is a heading</h1>