SlideShare uma empresa Scribd logo
1 de 13
Baixar para ler offline
HTML 5 Semantics

           - Prashanth Krish
               @Krish_Prashanth
HTML 5 Semantics                                     Open Web Technology Stack

What is presented in following slides?
  Discussion will be about semantic elements from Structure Layer present in
  Open Web Technology Stack and not on other items or other layers.
HTML 5 Semantics                                Personal Note




    HTML expands to Hyper Text Markup Language.
   It is NOT a styling language, you have CSS for that
    purpose. So stop abusing the existence of HTML.
HTML 5 Semantics                                            Semantic Tags


List of Semantic/Structural Elements – Alphabetical order


           <article>
           <aside>
           <bdi>
           <command>
           <details>                <ruby>
           <summary>                <rp>
           <figure>                 <rt>
           <figcaption>             <scetion>
           <footer>                 <time>
           <header>                 <wbr>
           <hgroup>
           <mark>
           <meter>
           <nav>
           <progress>
HTML 5 Semantics                                            OLDER SEMATICS




                            <div class=”header”>
                            My Company Logo
                            </div

                            <div id="main-nav" class="navigation">
 <div class="header">       <ul>
 <div class="navigation">   <li><a href="index.html">Home</a></li>
 <div class="footer">       <li><a href="/about/">About</a></li>
                            <li><a href="/blog/">Blog</a></li>
                            </ul>
                            </div>

                            <div class=”footer”>
                            Copyleft
                            </div>
HTML 5 Semantics                                    <Section>




 “The section element represents a generic section of a
 document or application. A section, in this context, is a
thematic grouping of content, typically with a heading.”
HTML 5 Semantics                                      <Section>


  “Authors are encouraged to use the article element
  instead of the section element when it would make
    sense to syndicate the contents of the element.”


      “The section element is not a generic container
     element. When an element is needed for styling
 purposes or as a convenience for scripting, authors are
  encouraged to use the div element instead. A general
 rule is that the section element is appropriate only if the
    element’s contents would be listed explicitly in the
                    document’s outline.”
HTML 5 Semantics                                                                     <Section>



 Do's

 •
   DO use section for each individual section of a tab switcher or content slider (if
 an unordered list isn’t needed)
 •
   DO use section to divide a lengthy “terms and conditions” (or similar) page into
 numbered sections
 •
   DO nest section elements if necessary (as you might do with the “terms and
 conditions” page)
 •
   DO use section to divide the different sections of a one-page website or
 portfolio




                                                        http://www.impressivewebs.com/html5-section/
HTML 5 Semantics                                                                    <Section>



 Dont's

 •
    DON’T use section to divide content from the header and footer; use div
 instead
 •
    DON’T use section to wrap a tab switcher for DOM manipulation or styling
 •
    DON’T use section for sidebar or other tangentially-related content boxes; use
 aside instead
 •
    DON’T use section just to add a border or drop shadow around something; use
 div instead
 •
    DON’T use section for the wrapper when implementing faux columns; again,
 use div instead
 •
    DON’T use section to nest elements when trying to avoid IE6′s float double-
 margin bug (or a similar layout-related issue); again, use div
 •
    DON’T use section to hold an individual author bio on a blog post or news
 article; use aside instead




                                                       http://www.impressivewebs.com/html5-section/
HTML 5 Semantics                                             <Article >




     "An article element represents a self-contained
  composition in a document, page, application, or site
  and that is, in principle, independently distributable or
 reusable, e.g. in syndication. This could be a forum post,
  a magazine or newspaper article, a blog entry, a user-
  submitted comment, an interactive widget or gadget,
       or any other independent item of content."


Syndication means that this article of content could stand
alone if needed and you would have all the information you
need to understand what it was and where it came from
HTML 5 Semantics                                         <Aside >



    “ The aside element represents a section of a page
 that consists of content that is tangentially related to the
 content around the aside element, and which could be
  considered separate from that content. Such sections
 are often represented as sidebars in printed typography.

     The element can be used for typographical effects
 like pull quotes or sidebars, for advertising, for groups of
 nav elements, and for other content that is considered
      separate from the main content of the page.”
HTML 5 Semantics                                                       A Sample Code

   <header>                                   <article>
     <hgroup>                                  <header>
      <h1>Page Title</h1>                        <h2><a href="#">Article Title</a></h2>
      <h2>Page Subtitle</h2>                   </header>
     </hgroup>                                 <section>
    </header>                                   Some more large content
    <nav>                                      </section>
     <ul>                                     </article>
      <li><a href="#">Home</a></li>          </section>
      <li><a href="#">Tutorials</a></li>     <aside>
     </ul>                                    <h2>Top links</h2>
    </nav>                                    <ul>
    <section id="articles">                    <li><a ref="extl" href="#">Link 1</a></li>
     <article>                                 <li><a ref="extl" href="#">Link 2</a></li>
      <header>                                </ul>
       <h2>                                       <figure>
               <a href="#">Article                 <img src="..."/>
Title</a></h2>                                     <figcaption>Chart 1.1</figcaption>
      </header>                                    </figure>
      <section>                              </aside>
       Big content goes here               <footer>
      </section>                             Footer content
     </article>                            </footer>
HTML 5 Semantics                                            References /ATTRIBUTION



  http://www.adobe.com/devnet/dreamweaver/articles/understanding-html5-
  semantics.html




                    This work is licensed under a
      Creative Commons Attribution-ShareAlike 3.0 Unported License.

Mais conteúdo relacionado

Mais procurados

A Power User's Intro to jQuery Awesomeness in SharePoint
A Power User's Intro to jQuery Awesomeness in SharePointA Power User's Intro to jQuery Awesomeness in SharePoint
A Power User's Intro to jQuery Awesomeness in SharePointMark Rackley
 
HTML Semantic Elements
HTML Semantic ElementsHTML Semantic Elements
HTML Semantic ElementsReema
 
Customize Your Website With HTML5 and CSS3:
Customize Your Website With HTML5 and CSS3:Customize Your Website With HTML5 and CSS3:
Customize Your Website With HTML5 and CSS3:Reema
 
Html5 and-css3-overview
Html5 and-css3-overviewHtml5 and-css3-overview
Html5 and-css3-overviewJacob Nelson
 
Introduction to StratusForms #SayNoToInfoPath
Introduction to StratusForms #SayNoToInfoPathIntroduction to StratusForms #SayNoToInfoPath
Introduction to StratusForms #SayNoToInfoPathMark Rackley
 
Web development Training in Ambala ! Batra Computer Centre
Web development Training in Ambala ! Batra Computer CentreWeb development Training in Ambala ! Batra Computer Centre
Web development Training in Ambala ! Batra Computer Centrejatin batra
 
SPTechCon Boston 2015 - Utilizing jQuery in SharePoint
SPTechCon Boston 2015 - Utilizing jQuery in SharePointSPTechCon Boston 2015 - Utilizing jQuery in SharePoint
SPTechCon Boston 2015 - Utilizing jQuery in SharePointMark Rackley
 
Web design - HTML (Hypertext Markup Language) introduction
Web design - HTML (Hypertext Markup Language) introductionWeb design - HTML (Hypertext Markup Language) introduction
Web design - HTML (Hypertext Markup Language) introductionMustafa Kamel Mohammadi
 
HYF - Class 01 - HTML And CSS
HYF - Class 01 - HTML And CSSHYF - Class 01 - HTML And CSS
HYF - Class 01 - HTML And CSSGarima Kaila
 
Html_Day_One (W3Schools)
Html_Day_One (W3Schools)Html_Day_One (W3Schools)
Html_Day_One (W3Schools)Rafi Haidari
 
Content query web part – get it all in one place and style it!
Content query web part – get it all in one place and style it!Content query web part – get it all in one place and style it!
Content query web part – get it all in one place and style it!Benjamin Niaulin
 
Intro to HTML and CSS
Intro to HTML and CSSIntro to HTML and CSS
Intro to HTML and CSSlexinamer
 
HTML_Day_Two(W3Schools)
HTML_Day_Two(W3Schools)HTML_Day_Two(W3Schools)
HTML_Day_Two(W3Schools)Rafi Haidari
 
Using jQuery to Maximize Form Usability
Using jQuery to Maximize Form UsabilityUsing jQuery to Maximize Form Usability
Using jQuery to Maximize Form UsabilityMark Rackley
 
SPTechCon DevDays - SharePoint & jQuery
SPTechCon DevDays - SharePoint & jQuerySPTechCon DevDays - SharePoint & jQuery
SPTechCon DevDays - SharePoint & jQueryMark Rackley
 

Mais procurados (20)

A Power User's Intro to jQuery Awesomeness in SharePoint
A Power User's Intro to jQuery Awesomeness in SharePointA Power User's Intro to jQuery Awesomeness in SharePoint
A Power User's Intro to jQuery Awesomeness in SharePoint
 
HTML Semantic Elements
HTML Semantic ElementsHTML Semantic Elements
HTML Semantic Elements
 
Basic html
Basic htmlBasic html
Basic html
 
Customize Your Website With HTML5 and CSS3:
Customize Your Website With HTML5 and CSS3:Customize Your Website With HTML5 and CSS3:
Customize Your Website With HTML5 and CSS3:
 
Html5 and-css3-overview
Html5 and-css3-overviewHtml5 and-css3-overview
Html5 and-css3-overview
 
Introduction to StratusForms #SayNoToInfoPath
Introduction to StratusForms #SayNoToInfoPathIntroduction to StratusForms #SayNoToInfoPath
Introduction to StratusForms #SayNoToInfoPath
 
Web development Training in Ambala ! Batra Computer Centre
Web development Training in Ambala ! Batra Computer CentreWeb development Training in Ambala ! Batra Computer Centre
Web development Training in Ambala ! Batra Computer Centre
 
Html 5
Html 5Html 5
Html 5
 
SPTechCon Boston 2015 - Utilizing jQuery in SharePoint
SPTechCon Boston 2015 - Utilizing jQuery in SharePointSPTechCon Boston 2015 - Utilizing jQuery in SharePoint
SPTechCon Boston 2015 - Utilizing jQuery in SharePoint
 
Html 5
Html 5Html 5
Html 5
 
Web design - HTML (Hypertext Markup Language) introduction
Web design - HTML (Hypertext Markup Language) introductionWeb design - HTML (Hypertext Markup Language) introduction
Web design - HTML (Hypertext Markup Language) introduction
 
HYF - Class 01 - HTML And CSS
HYF - Class 01 - HTML And CSSHYF - Class 01 - HTML And CSS
HYF - Class 01 - HTML And CSS
 
Html_Day_One (W3Schools)
Html_Day_One (W3Schools)Html_Day_One (W3Schools)
Html_Day_One (W3Schools)
 
Html introduction
Html introductionHtml introduction
Html introduction
 
Content query web part – get it all in one place and style it!
Content query web part – get it all in one place and style it!Content query web part – get it all in one place and style it!
Content query web part – get it all in one place and style it!
 
Intro to HTML and CSS
Intro to HTML and CSSIntro to HTML and CSS
Intro to HTML and CSS
 
Intro to HTML
Intro to HTMLIntro to HTML
Intro to HTML
 
HTML_Day_Two(W3Schools)
HTML_Day_Two(W3Schools)HTML_Day_Two(W3Schools)
HTML_Day_Two(W3Schools)
 
Using jQuery to Maximize Form Usability
Using jQuery to Maximize Form UsabilityUsing jQuery to Maximize Form Usability
Using jQuery to Maximize Form Usability
 
SPTechCon DevDays - SharePoint & jQuery
SPTechCon DevDays - SharePoint & jQuerySPTechCon DevDays - SharePoint & jQuery
SPTechCon DevDays - SharePoint & jQuery
 

Semelhante a Html5 semantics

Html 5, a gentle introduction
Html 5, a gentle introductionHtml 5, a gentle introduction
Html 5, a gentle introductionDiego Scataglini
 
Html5, a gentle introduction
Html5, a gentle introduction Html5, a gentle introduction
Html5, a gentle introduction Diego Scataglini
 
Html5 quick-learning-quide
Html5 quick-learning-quideHtml5 quick-learning-quide
Html5 quick-learning-quideAshok Suragala
 
Html5 quick-learning-quide
Html5 quick-learning-quideHtml5 quick-learning-quide
Html5 quick-learning-quideJerry Wijaya
 
Html5 quick-learning-quide
Html5 quick-learning-quideHtml5 quick-learning-quide
Html5 quick-learning-quidePL dream
 
Beginning Html 5 Presentation
Beginning Html 5 PresentationBeginning Html 5 Presentation
Beginning Html 5 PresentationUsman Saleem
 
Introduction to HTML.pptx
Introduction to HTML.pptxIntroduction to HTML.pptx
Introduction to HTML.pptxmalrad1
 
Html5 p resentation by techmodi
Html5 p resentation by techmodiHtml5 p resentation by techmodi
Html5 p resentation by techmoditechmodi_India
 
What is HTML - An Introduction to HTML (Hypertext Markup Language)
What is HTML - An Introduction to HTML (Hypertext Markup Language)What is HTML - An Introduction to HTML (Hypertext Markup Language)
What is HTML - An Introduction to HTML (Hypertext Markup Language)Ahsan Rahim
 
Frontend for developers
Frontend for developersFrontend for developers
Frontend for developersHernan Mammana
 
HTML Coding #01 : Don't Fear the Code
HTML Coding #01 : Don't Fear the CodeHTML Coding #01 : Don't Fear the Code
HTML Coding #01 : Don't Fear the CodeMichael Sturgeon
 
Front end full stack development module 1pptx
Front end full stack development module 1pptxFront end full stack development module 1pptx
Front end full stack development module 1pptxMaruthiPrasad96
 
Semantic HTML5
Semantic HTML5Semantic HTML5
Semantic HTML5Terry Ryan
 
46h interaction 1.lesson Hello world
46h interaction 1.lesson Hello world46h interaction 1.lesson Hello world
46h interaction 1.lesson Hello worldhemi46h
 
Three quick accessibility tips for HTML5
Three quick accessibility tips for HTML5Three quick accessibility tips for HTML5
Three quick accessibility tips for HTML5Russ Weakley
 
Introduction to HTML5
Introduction to HTML5Introduction to HTML5
Introduction to HTML5Terry Ryan
 

Semelhante a Html5 semantics (20)

Html 5, a gentle introduction
Html 5, a gentle introductionHtml 5, a gentle introduction
Html 5, a gentle introduction
 
Html5, a gentle introduction
Html5, a gentle introduction Html5, a gentle introduction
Html5, a gentle introduction
 
Html5 quick learning guide
Html5 quick learning guideHtml5 quick learning guide
Html5 quick learning guide
 
Html5 quick-learning-quide
Html5 quick-learning-quideHtml5 quick-learning-quide
Html5 quick-learning-quide
 
Html5 quick-learning-quide
Html5 quick-learning-quideHtml5 quick-learning-quide
Html5 quick-learning-quide
 
Html5 quick-learning-quide
Html5 quick-learning-quideHtml5 quick-learning-quide
Html5 quick-learning-quide
 
HTML5 introduction
HTML5 introductionHTML5 introduction
HTML5 introduction
 
Beginning Html 5 Presentation
Beginning Html 5 PresentationBeginning Html 5 Presentation
Beginning Html 5 Presentation
 
Introduction to HTML.pptx
Introduction to HTML.pptxIntroduction to HTML.pptx
Introduction to HTML.pptx
 
Html5 p resentation by techmodi
Html5 p resentation by techmodiHtml5 p resentation by techmodi
Html5 p resentation by techmodi
 
What is HTML - An Introduction to HTML (Hypertext Markup Language)
What is HTML - An Introduction to HTML (Hypertext Markup Language)What is HTML - An Introduction to HTML (Hypertext Markup Language)
What is HTML - An Introduction to HTML (Hypertext Markup Language)
 
Header,nav,footer
Header,nav,footerHeader,nav,footer
Header,nav,footer
 
Html5
Html5Html5
Html5
 
Frontend for developers
Frontend for developersFrontend for developers
Frontend for developers
 
HTML Coding #01 : Don't Fear the Code
HTML Coding #01 : Don't Fear the CodeHTML Coding #01 : Don't Fear the Code
HTML Coding #01 : Don't Fear the Code
 
Front end full stack development module 1pptx
Front end full stack development module 1pptxFront end full stack development module 1pptx
Front end full stack development module 1pptx
 
Semantic HTML5
Semantic HTML5Semantic HTML5
Semantic HTML5
 
46h interaction 1.lesson Hello world
46h interaction 1.lesson Hello world46h interaction 1.lesson Hello world
46h interaction 1.lesson Hello world
 
Three quick accessibility tips for HTML5
Three quick accessibility tips for HTML5Three quick accessibility tips for HTML5
Three quick accessibility tips for HTML5
 
Introduction to HTML5
Introduction to HTML5Introduction to HTML5
Introduction to HTML5
 

Último

How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerThousandEyes
 
A Year of the Servo Reboot: Where Are We Now?
A Year of the Servo Reboot: Where Are We Now?A Year of the Servo Reboot: Where Are We Now?
A Year of the Servo Reboot: Where Are We Now?Igalia
 
Factors to Consider When Choosing Accounts Payable Services Providers.pptx
Factors to Consider When Choosing Accounts Payable Services Providers.pptxFactors to Consider When Choosing Accounts Payable Services Providers.pptx
Factors to Consider When Choosing Accounts Payable Services Providers.pptxKatpro Technologies
 
Understanding Discord NSFW Servers A Guide for Responsible Users.pdf
Understanding Discord NSFW Servers A Guide for Responsible Users.pdfUnderstanding Discord NSFW Servers A Guide for Responsible Users.pdf
Understanding Discord NSFW Servers A Guide for Responsible Users.pdfUK Journal
 
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...Neo4j
 
Slack Application Development 101 Slides
Slack Application Development 101 SlidesSlack Application Development 101 Slides
Slack Application Development 101 Slidespraypatel2
 
Advantages of Hiring UIUX Design Service Providers for Your Business
Advantages of Hiring UIUX Design Service Providers for Your BusinessAdvantages of Hiring UIUX Design Service Providers for Your Business
Advantages of Hiring UIUX Design Service Providers for Your BusinessPixlogix Infotech
 
08448380779 Call Girls In Greater Kailash - I Women Seeking Men
08448380779 Call Girls In Greater Kailash - I Women Seeking Men08448380779 Call Girls In Greater Kailash - I Women Seeking Men
08448380779 Call Girls In Greater Kailash - I Women Seeking MenDelhi Call girls
 
The Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptxThe Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptxMalak Abu Hammad
 
Real Time Object Detection Using Open CV
Real Time Object Detection Using Open CVReal Time Object Detection Using Open CV
Real Time Object Detection Using Open CVKhem
 
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law DevelopmentsTrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law DevelopmentsTrustArc
 
IAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI SolutionsIAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI SolutionsEnterprise Knowledge
 
Scaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationScaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationRadu Cotescu
 
Automating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps ScriptAutomating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps Scriptwesley chun
 
Boost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivityBoost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivityPrincipled Technologies
 
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking MenDelhi Call girls
 
Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024The Digital Insurer
 
How to convert PDF to text with Nanonets
How to convert PDF to text with NanonetsHow to convert PDF to text with Nanonets
How to convert PDF to text with Nanonetsnaman860154
 
Driving Behavioral Change for Information Management through Data-Driven Gree...
Driving Behavioral Change for Information Management through Data-Driven Gree...Driving Behavioral Change for Information Management through Data-Driven Gree...
Driving Behavioral Change for Information Management through Data-Driven Gree...Enterprise Knowledge
 
Presentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreterPresentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreternaman860154
 

Último (20)

How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected Worker
 
A Year of the Servo Reboot: Where Are We Now?
A Year of the Servo Reboot: Where Are We Now?A Year of the Servo Reboot: Where Are We Now?
A Year of the Servo Reboot: Where Are We Now?
 
Factors to Consider When Choosing Accounts Payable Services Providers.pptx
Factors to Consider When Choosing Accounts Payable Services Providers.pptxFactors to Consider When Choosing Accounts Payable Services Providers.pptx
Factors to Consider When Choosing Accounts Payable Services Providers.pptx
 
Understanding Discord NSFW Servers A Guide for Responsible Users.pdf
Understanding Discord NSFW Servers A Guide for Responsible Users.pdfUnderstanding Discord NSFW Servers A Guide for Responsible Users.pdf
Understanding Discord NSFW Servers A Guide for Responsible Users.pdf
 
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
 
Slack Application Development 101 Slides
Slack Application Development 101 SlidesSlack Application Development 101 Slides
Slack Application Development 101 Slides
 
Advantages of Hiring UIUX Design Service Providers for Your Business
Advantages of Hiring UIUX Design Service Providers for Your BusinessAdvantages of Hiring UIUX Design Service Providers for Your Business
Advantages of Hiring UIUX Design Service Providers for Your Business
 
08448380779 Call Girls In Greater Kailash - I Women Seeking Men
08448380779 Call Girls In Greater Kailash - I Women Seeking Men08448380779 Call Girls In Greater Kailash - I Women Seeking Men
08448380779 Call Girls In Greater Kailash - I Women Seeking Men
 
The Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptxThe Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptx
 
Real Time Object Detection Using Open CV
Real Time Object Detection Using Open CVReal Time Object Detection Using Open CV
Real Time Object Detection Using Open CV
 
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law DevelopmentsTrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
 
IAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI SolutionsIAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI Solutions
 
Scaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationScaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organization
 
Automating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps ScriptAutomating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps Script
 
Boost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivityBoost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivity
 
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
 
Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024
 
How to convert PDF to text with Nanonets
How to convert PDF to text with NanonetsHow to convert PDF to text with Nanonets
How to convert PDF to text with Nanonets
 
Driving Behavioral Change for Information Management through Data-Driven Gree...
Driving Behavioral Change for Information Management through Data-Driven Gree...Driving Behavioral Change for Information Management through Data-Driven Gree...
Driving Behavioral Change for Information Management through Data-Driven Gree...
 
Presentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreterPresentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreter
 

Html5 semantics

  • 1. HTML 5 Semantics - Prashanth Krish @Krish_Prashanth
  • 2. HTML 5 Semantics Open Web Technology Stack What is presented in following slides? Discussion will be about semantic elements from Structure Layer present in Open Web Technology Stack and not on other items or other layers.
  • 3. HTML 5 Semantics Personal Note HTML expands to Hyper Text Markup Language. It is NOT a styling language, you have CSS for that purpose. So stop abusing the existence of HTML.
  • 4. HTML 5 Semantics Semantic Tags List of Semantic/Structural Elements – Alphabetical order <article> <aside> <bdi> <command> <details> <ruby> <summary> <rp> <figure> <rt> <figcaption> <scetion> <footer> <time> <header> <wbr> <hgroup> <mark> <meter> <nav> <progress>
  • 5. HTML 5 Semantics OLDER SEMATICS <div class=”header”> My Company Logo </div <div id="main-nav" class="navigation"> <div class="header"> <ul> <div class="navigation"> <li><a href="index.html">Home</a></li> <div class="footer"> <li><a href="/about/">About</a></li> <li><a href="/blog/">Blog</a></li> </ul> </div> <div class=”footer”> Copyleft </div>
  • 6. HTML 5 Semantics <Section> “The section element represents a generic section of a document or application. A section, in this context, is a thematic grouping of content, typically with a heading.”
  • 7. HTML 5 Semantics <Section> “Authors are encouraged to use the article element instead of the section element when it would make sense to syndicate the contents of the element.” “The section element is not a generic container element. When an element is needed for styling purposes or as a convenience for scripting, authors are encouraged to use the div element instead. A general rule is that the section element is appropriate only if the element’s contents would be listed explicitly in the document’s outline.”
  • 8. HTML 5 Semantics <Section> Do's • DO use section for each individual section of a tab switcher or content slider (if an unordered list isn’t needed) • DO use section to divide a lengthy “terms and conditions” (or similar) page into numbered sections • DO nest section elements if necessary (as you might do with the “terms and conditions” page) • DO use section to divide the different sections of a one-page website or portfolio http://www.impressivewebs.com/html5-section/
  • 9. HTML 5 Semantics <Section> Dont's • DON’T use section to divide content from the header and footer; use div instead • DON’T use section to wrap a tab switcher for DOM manipulation or styling • DON’T use section for sidebar or other tangentially-related content boxes; use aside instead • DON’T use section just to add a border or drop shadow around something; use div instead • DON’T use section for the wrapper when implementing faux columns; again, use div instead • DON’T use section to nest elements when trying to avoid IE6′s float double- margin bug (or a similar layout-related issue); again, use div • DON’T use section to hold an individual author bio on a blog post or news article; use aside instead http://www.impressivewebs.com/html5-section/
  • 10. HTML 5 Semantics <Article > "An article element represents a self-contained composition in a document, page, application, or site and that is, in principle, independently distributable or reusable, e.g. in syndication. This could be a forum post, a magazine or newspaper article, a blog entry, a user- submitted comment, an interactive widget or gadget, or any other independent item of content." Syndication means that this article of content could stand alone if needed and you would have all the information you need to understand what it was and where it came from
  • 11. HTML 5 Semantics <Aside > “ The aside element represents a section of a page that consists of content that is tangentially related to the content around the aside element, and which could be considered separate from that content. Such sections are often represented as sidebars in printed typography. The element can be used for typographical effects like pull quotes or sidebars, for advertising, for groups of nav elements, and for other content that is considered separate from the main content of the page.”
  • 12. HTML 5 Semantics A Sample Code <header> <article> <hgroup> <header> <h1>Page Title</h1> <h2><a href="#">Article Title</a></h2> <h2>Page Subtitle</h2> </header> </hgroup> <section> </header> Some more large content <nav> </section> <ul> </article> <li><a href="#">Home</a></li> </section> <li><a href="#">Tutorials</a></li> <aside> </ul> <h2>Top links</h2> </nav> <ul> <section id="articles"> <li><a ref="extl" href="#">Link 1</a></li> <article> <li><a ref="extl" href="#">Link 2</a></li> <header> </ul> <h2> <figure> <a href="#">Article <img src="..."/> Title</a></h2> <figcaption>Chart 1.1</figcaption> </header> </figure> <section> </aside> Big content goes here <footer> </section> Footer content </article> </footer>
  • 13. HTML 5 Semantics References /ATTRIBUTION http://www.adobe.com/devnet/dreamweaver/articles/understanding-html5- semantics.html This work is licensed under a Creative Commons Attribution-ShareAlike 3.0 Unported License.