SlideShare a Scribd company logo
Using
HTML5 & CSS3
   Today
Where we're at

•   Comfortable with HTML4 or XHTML and CSS2
•   Hearing talk of HTML5 and CSS3
•   Rapidly advancing browsers
•   ...but we've still got IE6
HTML5 and CSS3 are ready

• Dispelling some myths
• How to begin using them today
What HTML5 is

• HTML5 is the next iteration of web page markup
• HTML4 -> XHTML 1 -> XHTML 2 -> HTML5
• Introduces new tags and attributes
   o <header>, <footer>, <nav>, <section>...
   o <input type="email">
• Designed for web apps
• Already understood by all browsers
   o Even IE6!
Myth: It's not done yet

• "The HTML5 spec won't be done until 2012 or 2022"
• Reality: 
   o Browser support is what matters
   o 2022: "Proposed Recommendation"
       Meaningless in a practical sense
   o 2012: "Candidate Recommendation"
       Spec is finished and ready for widespread adoption
   o But it's only 2011...
       ...browser support is what matters.

  o   CSS 2.1 is just now a final spec (2011)
        "Candidate Recommendation" in 2005
Myth: Browsers don't support it

• Reality:
   o Browsers don't support HTML4 or XHTML either -- they
     support a collection of tags and attributes
   o Browsers understand any <tagname>
   o Browsers will ignore HTML tag attributes and CSS
     properties that they don't understand
   o For JavaScript, use object detection or try/catch
   o Unrecognized <input> types are rendered as <input
      type="text">
  o   "The HTML5 specification is really just documenting what browsers already do." -
      HTML5 for Web Designers
Myth: My favorite tag will be obsolete

• Reality:
   o "Obsolete" != "deprecated"
   o Obsolescence is defined by browser support, and always
     has been
   o Alternatives are already in place for obsolete tags
Obsolete tag alternatives

• <font>
   o <span>
• <frame>, <noframe>, <frameset>
   o <iframe>, re-design with <div>s
• <acronym>
   o <abbr>
• tags: <big>, <strike>, <center>
  attributes: bgcolor, cellspacing, cellpadding,
  valign
   o Use CSS
Myth: It can't all be ready, can it?

• Reality: No, you're right, it's not all ready.
• Some elements are in a state of transition and need
  fallbacks (<video>, <canvas>)
• Some APIs are simply not close to being ready
  (WebSockets, form validation)
• However...
   o Cross-platform alternatives and sample fallbacks exist
     today
       offline storage
   o Some can be designed around
       A browser doesn't support geolocation? Ask the user
        for their ZIP code.
How do I start using it?

• <!DOCTYPE html>
• New elements:
   o Modern browsers: header { display: block; }
   o IE: shivs
• Keep your old syntax or adopt a new one
  o   <input type="text" />
  o   <input type="text">
  o   <input type=text>
• CSS3: just use it
   o IE 6-8: css3pie.com
Resources

• HTML5 tag
  list: www.w3schools.com/html5/html5_reference.asp
• CSS3 property list: modernizr.com/docs/
• Feature detection: Modernizr (includes shivs)
• Shivs: code.google.com/p/html5shiv
• html5boilerplate.com -- detailed page structure
• Gradient generator: colorzilla.com/gradient-editor/
• Try it yourself:
  o playground.html5rocks.com
  o css3please.com
• Keep tabs on browser support: caniuse.com
• These links and more: patik.com/html5/

More Related Content

What's hot

Web Development Basics: HOW TO in HTML
Web Development Basics: HOW TO in HTMLWeb Development Basics: HOW TO in HTML
Web Development Basics: HOW TO in HTML
Der Lo
 
What's a web page made of?
What's a web page made of?What's a web page made of?
What's a web page made of?
Charlie Allen
 
Ui devopler
Ui devoplerUi devopler
Ui devopler
Janu Jahnavi
 
Html5
Html5Html5
Introduction to HTML5 and CSS3 (revised)
Introduction to HTML5 and CSS3 (revised)Introduction to HTML5 and CSS3 (revised)
Introduction to HTML5 and CSS3 (revised)Joseph Lewis
 
JavaScript debugging diagnostic web tools and firefox
JavaScript debugging diagnostic web tools and firefoxJavaScript debugging diagnostic web tools and firefox
JavaScript debugging diagnostic web tools and firefoxGennady Feldman
 
Real World Web components
Real World Web componentsReal World Web components
Real World Web components
Jarrod Overson
 
Advance Css
Advance CssAdvance Css
Advance Css
vijayta
 
Advance Css 1194323118268797 5
Advance Css 1194323118268797 5Advance Css 1194323118268797 5
Advance Css 1194323118268797 5
dharshyamal
 
Web development basics (Part-1)
Web development basics (Part-1)Web development basics (Part-1)
Web development basics (Part-1)
Rajat Pratap Singh
 
Web design using html
Web design using htmlWeb design using html
Web design using html
ElsaS7
 
CSS Best practice
CSS Best practiceCSS Best practice
CSS Best practice
Russ Weakley
 

What's hot (13)

Web Development Basics: HOW TO in HTML
Web Development Basics: HOW TO in HTMLWeb Development Basics: HOW TO in HTML
Web Development Basics: HOW TO in HTML
 
What's a web page made of?
What's a web page made of?What's a web page made of?
What's a web page made of?
 
Ui devopler
Ui devoplerUi devopler
Ui devopler
 
Html5
Html5Html5
Html5
 
Introduction to HTML5 and CSS3 (revised)
Introduction to HTML5 and CSS3 (revised)Introduction to HTML5 and CSS3 (revised)
Introduction to HTML5 and CSS3 (revised)
 
JavaScript debugging diagnostic web tools and firefox
JavaScript debugging diagnostic web tools and firefoxJavaScript debugging diagnostic web tools and firefox
JavaScript debugging diagnostic web tools and firefox
 
Html5 public
Html5 publicHtml5 public
Html5 public
 
Real World Web components
Real World Web componentsReal World Web components
Real World Web components
 
Advance Css
Advance CssAdvance Css
Advance Css
 
Advance Css 1194323118268797 5
Advance Css 1194323118268797 5Advance Css 1194323118268797 5
Advance Css 1194323118268797 5
 
Web development basics (Part-1)
Web development basics (Part-1)Web development basics (Part-1)
Web development basics (Part-1)
 
Web design using html
Web design using htmlWeb design using html
Web design using html
 
CSS Best practice
CSS Best practiceCSS Best practice
CSS Best practice
 

Viewers also liked

Hutten Mvo Magazine 2011
Hutten Mvo Magazine 2011Hutten Mvo Magazine 2011
Hutten Mvo Magazine 2011Collin_S
 
豊洲スマートシティ
豊洲スマートシティ豊洲スマートシティ
豊洲スマートシティ優一 佐藤
 
循環バイオマス型都市
循環バイオマス型都市循環バイオマス型都市
循環バイオマス型都市優一 佐藤
 
参加の手引き(β版)
参加の手引き(β版)参加の手引き(β版)
参加の手引き(β版)優一 佐藤
 
Ysj2012 第4の革命
Ysj2012  第4の革命Ysj2012  第4の革命
Ysj2012 第4の革命
優一 佐藤
 
「Callingood(コーリングッド)」
「Callingood(コーリングッド)」「Callingood(コーリングッド)」
「Callingood(コーリングッド)」
優一 佐藤
 

Viewers also liked (6)

Hutten Mvo Magazine 2011
Hutten Mvo Magazine 2011Hutten Mvo Magazine 2011
Hutten Mvo Magazine 2011
 
豊洲スマートシティ
豊洲スマートシティ豊洲スマートシティ
豊洲スマートシティ
 
循環バイオマス型都市
循環バイオマス型都市循環バイオマス型都市
循環バイオマス型都市
 
参加の手引き(β版)
参加の手引き(β版)参加の手引き(β版)
参加の手引き(β版)
 
Ysj2012 第4の革命
Ysj2012  第4の革命Ysj2012  第4の革命
Ysj2012 第4の革命
 
「Callingood(コーリングッド)」
「Callingood(コーリングッド)」「Callingood(コーリングッド)」
「Callingood(コーリングッド)」
 

Similar to Html5

New Web Revolution - html5 and css3
New Web Revolution - html5 and css3New Web Revolution - html5 and css3
New Web Revolution - html5 and css3
Nitish Surelia
 
html5 css3 the future of web technology
html5 css3 the future of web technologyhtml5 css3 the future of web technology
html5 css3 the future of web technologyhazzaz
 
Html5 with SharePoint 2010
Html5 with SharePoint 2010Html5 with SharePoint 2010
Html5 with SharePoint 2010
Hemant Joshi
 
HTML5 History & Features
HTML5 History & FeaturesHTML5 History & Features
HTML5 History & Features
Dave Ross
 
Chapter 2 introduction to html5
Chapter 2 introduction to html5Chapter 2 introduction to html5
Chapter 2 introduction to html5
nobel mujuji
 
The web standards gentleman: a matter of (evolving) standards)
The web standards gentleman: a matter of (evolving) standards)The web standards gentleman: a matter of (evolving) standards)
The web standards gentleman: a matter of (evolving) standards)
Chris Mills
 
Html,CSS & UI/UX design
Html,CSS & UI/UX designHtml,CSS & UI/UX design
Html,CSS & UI/UX design
Karthikeyan Dhanasekaran CUA
 
HTML5--The 30,000' View (A fast-paced overview of HTML5)
HTML5--The 30,000' View (A fast-paced overview of HTML5)HTML5--The 30,000' View (A fast-paced overview of HTML5)
HTML5--The 30,000' View (A fast-paced overview of HTML5)
Peter Lubbers
 
Html5 Flyover
Html5 FlyoverHtml5 Flyover
Html5 Flyover
Skills Matter
 
Html5 today
Html5 todayHtml5 today
Html5 todayRoy Yu
 
HTML5, just another presentation :)
HTML5, just another presentation :)HTML5, just another presentation :)
HTML5, just another presentation :)
François Massart
 
HTML5
HTML5 HTML5
Is it time to start using HTML 5
Is it time to start using HTML 5Is it time to start using HTML 5
Is it time to start using HTML 5Ravi Raj
 
WHAT IS HTML5? (at CSS Nite Osaka)
WHAT IS HTML5? (at CSS Nite Osaka)WHAT IS HTML5? (at CSS Nite Osaka)
WHAT IS HTML5? (at CSS Nite Osaka)Shumpei Shiraishi
 
HTML5 and Joomla! 2.5 Template
HTML5 and Joomla! 2.5 TemplateHTML5 and Joomla! 2.5 Template
HTML5 and Joomla! 2.5 Template
Marvelic Engine Co., Ltd.
 
Html5 shubelal
Html5 shubelalHtml5 shubelal
Html5 shubelal
Shub
 
Screw HTML5, make cool shit with AIR
Screw HTML5, make cool shit with AIRScrew HTML5, make cool shit with AIR
Screw HTML5, make cool shit with AIR
Eric Fickes
 
HTML 5 Complete Reference
HTML 5 Complete ReferenceHTML 5 Complete Reference
HTML 5 Complete Reference
EPAM Systems
 

Similar to Html5 (20)

New Web Revolution - html5 and css3
New Web Revolution - html5 and css3New Web Revolution - html5 and css3
New Web Revolution - html5 and css3
 
HTML 5
HTML 5HTML 5
HTML 5
 
html5 css3 the future of web technology
html5 css3 the future of web technologyhtml5 css3 the future of web technology
html5 css3 the future of web technology
 
Html5 with SharePoint 2010
Html5 with SharePoint 2010Html5 with SharePoint 2010
Html5 with SharePoint 2010
 
HTML5 History & Features
HTML5 History & FeaturesHTML5 History & Features
HTML5 History & Features
 
Chapter 2 introduction to html5
Chapter 2 introduction to html5Chapter 2 introduction to html5
Chapter 2 introduction to html5
 
The web standards gentleman: a matter of (evolving) standards)
The web standards gentleman: a matter of (evolving) standards)The web standards gentleman: a matter of (evolving) standards)
The web standards gentleman: a matter of (evolving) standards)
 
Html,CSS & UI/UX design
Html,CSS & UI/UX designHtml,CSS & UI/UX design
Html,CSS & UI/UX design
 
HTML5--The 30,000' View (A fast-paced overview of HTML5)
HTML5--The 30,000' View (A fast-paced overview of HTML5)HTML5--The 30,000' View (A fast-paced overview of HTML5)
HTML5--The 30,000' View (A fast-paced overview of HTML5)
 
Html5 Flyover
Html5 FlyoverHtml5 Flyover
Html5 Flyover
 
Html5 today
Html5 todayHtml5 today
Html5 today
 
HTML5, just another presentation :)
HTML5, just another presentation :)HTML5, just another presentation :)
HTML5, just another presentation :)
 
HTML5
HTML5 HTML5
HTML5
 
Is it time to start using HTML 5
Is it time to start using HTML 5Is it time to start using HTML 5
Is it time to start using HTML 5
 
WHAT IS HTML5? (at CSS Nite Osaka)
WHAT IS HTML5? (at CSS Nite Osaka)WHAT IS HTML5? (at CSS Nite Osaka)
WHAT IS HTML5? (at CSS Nite Osaka)
 
Html5 n css3
Html5 n css3Html5 n css3
Html5 n css3
 
HTML5 and Joomla! 2.5 Template
HTML5 and Joomla! 2.5 TemplateHTML5 and Joomla! 2.5 Template
HTML5 and Joomla! 2.5 Template
 
Html5 shubelal
Html5 shubelalHtml5 shubelal
Html5 shubelal
 
Screw HTML5, make cool shit with AIR
Screw HTML5, make cool shit with AIRScrew HTML5, make cool shit with AIR
Screw HTML5, make cool shit with AIR
 
HTML 5 Complete Reference
HTML 5 Complete ReferenceHTML 5 Complete Reference
HTML 5 Complete Reference
 

Recently uploaded

The Diamonds of 2023-2024 in the IGRA collection
The Diamonds of 2023-2024 in the IGRA collectionThe Diamonds of 2023-2024 in the IGRA collection
The Diamonds of 2023-2024 in the IGRA collection
Israel Genealogy Research Association
 
The simplified electron and muon model, Oscillating Spacetime: The Foundation...
The simplified electron and muon model, Oscillating Spacetime: The Foundation...The simplified electron and muon model, Oscillating Spacetime: The Foundation...
The simplified electron and muon model, Oscillating Spacetime: The Foundation...
RitikBhardwaj56
 
Normal Labour/ Stages of Labour/ Mechanism of Labour
Normal Labour/ Stages of Labour/ Mechanism of LabourNormal Labour/ Stages of Labour/ Mechanism of Labour
Normal Labour/ Stages of Labour/ Mechanism of Labour
Wasim Ak
 
Landownership in the Philippines under the Americans-2-pptx.pptx
Landownership in the Philippines under the Americans-2-pptx.pptxLandownership in the Philippines under the Americans-2-pptx.pptx
Landownership in the Philippines under the Americans-2-pptx.pptx
JezreelCabil2
 
Thesis Statement for students diagnonsed withADHD.ppt
Thesis Statement for students diagnonsed withADHD.pptThesis Statement for students diagnonsed withADHD.ppt
Thesis Statement for students diagnonsed withADHD.ppt
EverAndrsGuerraGuerr
 
Best Digital Marketing Institute In NOIDA
Best Digital Marketing Institute In NOIDABest Digital Marketing Institute In NOIDA
Best Digital Marketing Institute In NOIDA
deeptiverma2406
 
S1-Introduction-Biopesticides in ICM.pptx
S1-Introduction-Biopesticides in ICM.pptxS1-Introduction-Biopesticides in ICM.pptx
S1-Introduction-Biopesticides in ICM.pptx
tarandeep35
 
Digital Artifact 1 - 10VCD Environments Unit
Digital Artifact 1 - 10VCD Environments UnitDigital Artifact 1 - 10VCD Environments Unit
Digital Artifact 1 - 10VCD Environments Unit
chanes7
 
How to Add Chatter in the odoo 17 ERP Module
How to Add Chatter in the odoo 17 ERP ModuleHow to Add Chatter in the odoo 17 ERP Module
How to Add Chatter in the odoo 17 ERP Module
Celine George
 
A Strategic Approach: GenAI in Education
A Strategic Approach: GenAI in EducationA Strategic Approach: GenAI in Education
A Strategic Approach: GenAI in Education
Peter Windle
 
PCOS corelations and management through Ayurveda.
PCOS corelations and management through Ayurveda.PCOS corelations and management through Ayurveda.
PCOS corelations and management through Ayurveda.
Dr. Shivangi Singh Parihar
 
South African Journal of Science: Writing with integrity workshop (2024)
South African Journal of Science: Writing with integrity workshop (2024)South African Journal of Science: Writing with integrity workshop (2024)
South African Journal of Science: Writing with integrity workshop (2024)
Academy of Science of South Africa
 
MASS MEDIA STUDIES-835-CLASS XI Resource Material.pdf
MASS MEDIA STUDIES-835-CLASS XI Resource Material.pdfMASS MEDIA STUDIES-835-CLASS XI Resource Material.pdf
MASS MEDIA STUDIES-835-CLASS XI Resource Material.pdf
goswamiyash170123
 
2024.06.01 Introducing a competency framework for languag learning materials ...
2024.06.01 Introducing a competency framework for languag learning materials ...2024.06.01 Introducing a competency framework for languag learning materials ...
2024.06.01 Introducing a competency framework for languag learning materials ...
Sandy Millin
 
Azure Interview Questions and Answers PDF By ScholarHat
Azure Interview Questions and Answers PDF By ScholarHatAzure Interview Questions and Answers PDF By ScholarHat
Azure Interview Questions and Answers PDF By ScholarHat
Scholarhat
 
CACJapan - GROUP Presentation 1- Wk 4.pdf
CACJapan - GROUP Presentation 1- Wk 4.pdfCACJapan - GROUP Presentation 1- Wk 4.pdf
CACJapan - GROUP Presentation 1- Wk 4.pdf
camakaiclarkmusic
 
"Protectable subject matters, Protection in biotechnology, Protection of othe...
"Protectable subject matters, Protection in biotechnology, Protection of othe..."Protectable subject matters, Protection in biotechnology, Protection of othe...
"Protectable subject matters, Protection in biotechnology, Protection of othe...
SACHIN R KONDAGURI
 
How to Build a Module in Odoo 17 Using the Scaffold Method
How to Build a Module in Odoo 17 Using the Scaffold MethodHow to Build a Module in Odoo 17 Using the Scaffold Method
How to Build a Module in Odoo 17 Using the Scaffold Method
Celine George
 
Digital Artefact 1 - Tiny Home Environmental Design
Digital Artefact 1 - Tiny Home Environmental DesignDigital Artefact 1 - Tiny Home Environmental Design
Digital Artefact 1 - Tiny Home Environmental Design
amberjdewit93
 
BÀI TẬP BỔ TRỢ TIẾNG ANH GLOBAL SUCCESS LỚP 3 - CẢ NĂM (CÓ FILE NGHE VÀ ĐÁP Á...
BÀI TẬP BỔ TRỢ TIẾNG ANH GLOBAL SUCCESS LỚP 3 - CẢ NĂM (CÓ FILE NGHE VÀ ĐÁP Á...BÀI TẬP BỔ TRỢ TIẾNG ANH GLOBAL SUCCESS LỚP 3 - CẢ NĂM (CÓ FILE NGHE VÀ ĐÁP Á...
BÀI TẬP BỔ TRỢ TIẾNG ANH GLOBAL SUCCESS LỚP 3 - CẢ NĂM (CÓ FILE NGHE VÀ ĐÁP Á...
Nguyen Thanh Tu Collection
 

Recently uploaded (20)

The Diamonds of 2023-2024 in the IGRA collection
The Diamonds of 2023-2024 in the IGRA collectionThe Diamonds of 2023-2024 in the IGRA collection
The Diamonds of 2023-2024 in the IGRA collection
 
The simplified electron and muon model, Oscillating Spacetime: The Foundation...
The simplified electron and muon model, Oscillating Spacetime: The Foundation...The simplified electron and muon model, Oscillating Spacetime: The Foundation...
The simplified electron and muon model, Oscillating Spacetime: The Foundation...
 
Normal Labour/ Stages of Labour/ Mechanism of Labour
Normal Labour/ Stages of Labour/ Mechanism of LabourNormal Labour/ Stages of Labour/ Mechanism of Labour
Normal Labour/ Stages of Labour/ Mechanism of Labour
 
Landownership in the Philippines under the Americans-2-pptx.pptx
Landownership in the Philippines under the Americans-2-pptx.pptxLandownership in the Philippines under the Americans-2-pptx.pptx
Landownership in the Philippines under the Americans-2-pptx.pptx
 
Thesis Statement for students diagnonsed withADHD.ppt
Thesis Statement for students diagnonsed withADHD.pptThesis Statement for students diagnonsed withADHD.ppt
Thesis Statement for students diagnonsed withADHD.ppt
 
Best Digital Marketing Institute In NOIDA
Best Digital Marketing Institute In NOIDABest Digital Marketing Institute In NOIDA
Best Digital Marketing Institute In NOIDA
 
S1-Introduction-Biopesticides in ICM.pptx
S1-Introduction-Biopesticides in ICM.pptxS1-Introduction-Biopesticides in ICM.pptx
S1-Introduction-Biopesticides in ICM.pptx
 
Digital Artifact 1 - 10VCD Environments Unit
Digital Artifact 1 - 10VCD Environments UnitDigital Artifact 1 - 10VCD Environments Unit
Digital Artifact 1 - 10VCD Environments Unit
 
How to Add Chatter in the odoo 17 ERP Module
How to Add Chatter in the odoo 17 ERP ModuleHow to Add Chatter in the odoo 17 ERP Module
How to Add Chatter in the odoo 17 ERP Module
 
A Strategic Approach: GenAI in Education
A Strategic Approach: GenAI in EducationA Strategic Approach: GenAI in Education
A Strategic Approach: GenAI in Education
 
PCOS corelations and management through Ayurveda.
PCOS corelations and management through Ayurveda.PCOS corelations and management through Ayurveda.
PCOS corelations and management through Ayurveda.
 
South African Journal of Science: Writing with integrity workshop (2024)
South African Journal of Science: Writing with integrity workshop (2024)South African Journal of Science: Writing with integrity workshop (2024)
South African Journal of Science: Writing with integrity workshop (2024)
 
MASS MEDIA STUDIES-835-CLASS XI Resource Material.pdf
MASS MEDIA STUDIES-835-CLASS XI Resource Material.pdfMASS MEDIA STUDIES-835-CLASS XI Resource Material.pdf
MASS MEDIA STUDIES-835-CLASS XI Resource Material.pdf
 
2024.06.01 Introducing a competency framework for languag learning materials ...
2024.06.01 Introducing a competency framework for languag learning materials ...2024.06.01 Introducing a competency framework for languag learning materials ...
2024.06.01 Introducing a competency framework for languag learning materials ...
 
Azure Interview Questions and Answers PDF By ScholarHat
Azure Interview Questions and Answers PDF By ScholarHatAzure Interview Questions and Answers PDF By ScholarHat
Azure Interview Questions and Answers PDF By ScholarHat
 
CACJapan - GROUP Presentation 1- Wk 4.pdf
CACJapan - GROUP Presentation 1- Wk 4.pdfCACJapan - GROUP Presentation 1- Wk 4.pdf
CACJapan - GROUP Presentation 1- Wk 4.pdf
 
"Protectable subject matters, Protection in biotechnology, Protection of othe...
"Protectable subject matters, Protection in biotechnology, Protection of othe..."Protectable subject matters, Protection in biotechnology, Protection of othe...
"Protectable subject matters, Protection in biotechnology, Protection of othe...
 
How to Build a Module in Odoo 17 Using the Scaffold Method
How to Build a Module in Odoo 17 Using the Scaffold MethodHow to Build a Module in Odoo 17 Using the Scaffold Method
How to Build a Module in Odoo 17 Using the Scaffold Method
 
Digital Artefact 1 - Tiny Home Environmental Design
Digital Artefact 1 - Tiny Home Environmental DesignDigital Artefact 1 - Tiny Home Environmental Design
Digital Artefact 1 - Tiny Home Environmental Design
 
BÀI TẬP BỔ TRỢ TIẾNG ANH GLOBAL SUCCESS LỚP 3 - CẢ NĂM (CÓ FILE NGHE VÀ ĐÁP Á...
BÀI TẬP BỔ TRỢ TIẾNG ANH GLOBAL SUCCESS LỚP 3 - CẢ NĂM (CÓ FILE NGHE VÀ ĐÁP Á...BÀI TẬP BỔ TRỢ TIẾNG ANH GLOBAL SUCCESS LỚP 3 - CẢ NĂM (CÓ FILE NGHE VÀ ĐÁP Á...
BÀI TẬP BỔ TRỢ TIẾNG ANH GLOBAL SUCCESS LỚP 3 - CẢ NĂM (CÓ FILE NGHE VÀ ĐÁP Á...
 

Html5

  • 2. Where we're at • Comfortable with HTML4 or XHTML and CSS2 • Hearing talk of HTML5 and CSS3 • Rapidly advancing browsers • ...but we've still got IE6
  • 3. HTML5 and CSS3 are ready • Dispelling some myths • How to begin using them today
  • 4. What HTML5 is • HTML5 is the next iteration of web page markup • HTML4 -> XHTML 1 -> XHTML 2 -> HTML5 • Introduces new tags and attributes o <header>, <footer>, <nav>, <section>... o <input type="email"> • Designed for web apps • Already understood by all browsers o Even IE6!
  • 5. Myth: It's not done yet • "The HTML5 spec won't be done until 2012 or 2022" • Reality:  o Browser support is what matters o 2022: "Proposed Recommendation"  Meaningless in a practical sense o 2012: "Candidate Recommendation"  Spec is finished and ready for widespread adoption o But it's only 2011...  ...browser support is what matters. o CSS 2.1 is just now a final spec (2011)  "Candidate Recommendation" in 2005
  • 6. Myth: Browsers don't support it • Reality: o Browsers don't support HTML4 or XHTML either -- they support a collection of tags and attributes o Browsers understand any <tagname> o Browsers will ignore HTML tag attributes and CSS properties that they don't understand o For JavaScript, use object detection or try/catch o Unrecognized <input> types are rendered as <input type="text"> o "The HTML5 specification is really just documenting what browsers already do." - HTML5 for Web Designers
  • 7. Myth: My favorite tag will be obsolete • Reality: o "Obsolete" != "deprecated" o Obsolescence is defined by browser support, and always has been o Alternatives are already in place for obsolete tags
  • 8. Obsolete tag alternatives • <font> o <span> • <frame>, <noframe>, <frameset> o <iframe>, re-design with <div>s • <acronym> o <abbr> • tags: <big>, <strike>, <center> attributes: bgcolor, cellspacing, cellpadding, valign o Use CSS
  • 9. Myth: It can't all be ready, can it? • Reality: No, you're right, it's not all ready. • Some elements are in a state of transition and need fallbacks (<video>, <canvas>) • Some APIs are simply not close to being ready (WebSockets, form validation) • However... o Cross-platform alternatives and sample fallbacks exist today  offline storage o Some can be designed around  A browser doesn't support geolocation? Ask the user for their ZIP code.
  • 10. How do I start using it? • <!DOCTYPE html> • New elements: o Modern browsers: header { display: block; } o IE: shivs • Keep your old syntax or adopt a new one o <input type="text" /> o <input type="text"> o <input type=text> • CSS3: just use it o IE 6-8: css3pie.com
  • 11. Resources • HTML5 tag list: www.w3schools.com/html5/html5_reference.asp • CSS3 property list: modernizr.com/docs/ • Feature detection: Modernizr (includes shivs) • Shivs: code.google.com/p/html5shiv • html5boilerplate.com -- detailed page structure • Gradient generator: colorzilla.com/gradient-editor/ • Try it yourself: o playground.html5rocks.com o css3please.com • Keep tabs on browser support: caniuse.com • These links and more: patik.com/html5/