SlideShare a Scribd company logo
1 of 34
Guide to HTML 5
Ran Bar-Zik
PHPDrupal Developer
19.02.2014

Ā© Copyright 2012 Hewlett-Packard Development Company, L.P. The information contained herein is subject to change without notice.
Who am I?
Ran Bar-Zik,
ā€¢ PHP developer at HP Software
ā€¢ Working at hpln.hp.com
ā€¢ More information at my personal site: internet-israel.com

2

Ā© Copyright 2012 Hewlett-Packard Development Company, L.P. The information contained herein is subject to change without notice.
What is HTML5

Ā© Copyright 2012 Hewlett-Packard Development Company, L.P. The information contained herein is subject to change without notice.
Letā€™s talk about HTML 4
HTML standards are standards
HTML is Instructions for the browsers
ā€¢
ā€¢

For example: take this string: <h1>HEADER</h1> and show it in large font.
For example, take this string: <input type=ā€œtextā€ value=ā€œhelloā€ /> and show it like this:

ā€¢
ā€¢

For example: allow CSS to change the basic design of the elements (HTML 3)
The HTML standards are being defined by the W3C

4

Ā© Copyright 2012 Hewlett-Packard Development Company, L.P. The information contained herein is subject to change without notice.
HTML4 was great, really
It allowed us to create sophisticated, rich web sites

5

Ā© Copyright 2012 Hewlett-Packard Development Company, L.P. The information contained herein is subject to change without notice.
HTML4 needed a lot of code
And programmers hate a lot of code
A lot of code means headache:
1. We need to maintain it.
2. We need to keep it updated with every version of browser. Yes IE ā€“ I am looking at
you!
3. We need to QA it
4. We are lazy!

6

Ā© Copyright 2012 Hewlett-Packard Development Company, L.P. The information contained herein is subject to change without notice.
HTML5 to the rescue!
HTML5 allows us to do a lot of things, but with less code
HTML5 is a new standard that tells the browsers to do a lot more
For example, use this string
in order to create a placeholer:
In order to do it in HTML 4 we need to write a lot of JavaScript:

7

Ā© Copyright 2012 Hewlett-Packard Development Company, L.P. The information contained herein is subject to change without notice.
Some mind blowing HTML5 demos
Now I will amaze you!
https://developer.mozilla.org/en-US/demos/detail/zen-photongarden/launch
http://craftymind.com/factory/html5video/CanvasVideo.html [ff]
http://www.clicktorelease.com/code/css3dclouds/
http://hompimpa.googlecode.com/svn/trunk/CSS3-Windows7-StartMenus/index.html

8

Ā© Copyright 2012 Hewlett-Packard Development Company, L.P. The information contained herein is subject to change without notice.
HTML5 is more than way to save code
It allow us to do things that we canā€™t do previously
For example:
1. Cache control (no way to deal with it previously) and offline behavior.
2. Geo location (very hard and unreliable in the past).
3. A lot of nerdy things for programmers to drool about like promises in JS, web workers
etc. it allows us to create faster, reliable and efficient code.

9

Ā© Copyright 2012 Hewlett-Packard Development Company, L.P. The information contained herein is subject to change without notice.
The IE situation

Ā© Copyright 2012 Hewlett-Packard Development Company, L.P. The information contained herein is subject to change without notice.
The main problem with HTML5
Internet Explorer and other old browsers does not support it
Even new versions of Internet Explorer sometimes does not support part
of HTML5
Why?
Because IE suck. Thatā€™s why.
We have 3 ways to deal with it:

11

Ā© Copyright 2012 Hewlett-Packard Development Company, L.P. The information contained herein is subject to change without notice.
Polyfills
JavaScript file that fill the gap for old browsers
Allowing new features on old browsers
For example: allowing HTML5 form control on Internet Explorer 8 that does not support
this feature.
What is the problem?
ā€¢ Performance
ā€¢ Reliability
ā€¢ Sometimes there is no polyfill.

12

Ā© Copyright 2012 Hewlett-Packard Development Company, L.P. The information contained herein is subject to change without notice.
Fallbacks
Allow alternative solution for browsers that does not have the feature
For example:
Showing Flash videos for browsers that does not support HTML5 videos.
What is the problem?
ā€¢ Very inefficient
ā€¢ A lot of code
ā€¢ Annoying

13

Ā© Copyright 2012 Hewlett-Packard Development Company, L.P. The information contained herein is subject to change without notice.
Ignore old browsers
And there is no problem at allā€¦

14

Ā© Copyright 2012 Hewlett-Packard Development Company, L.P. The information contained herein is subject to change without notice.
HTML5 components: Video &
Audio

Ā© Copyright 2012 Hewlett-Packard Development Company, L.P. The information contained herein is subject to change without notice.
We donā€™t need no FLASH for that
Video and Audio become native to application
And you can do amazing things with that ā€“ natively!
http://www.apple.com/html5/showcase/video/

http://www.internet-israel.com/?p=3835

16

Ā© Copyright 2012 Hewlett-Packard Development Company, L.P. The information contained herein is subject to change without notice.
But why do we need it?
Video was there long before HTML5
Flash video suck
ā€¢
ā€¢
ā€¢
ā€¢
ā€¢

17

It is slow, unreliable and dependent on flash plug in.
It is not part of the page and it is very hard to control.
Very hard to play with.
Subtitles
Not supported on mobile.

Ā© Copyright 2012 Hewlett-Packard Development Company, L.P. The information contained herein is subject to change without notice.
HTML5 components:
Appcache

Ā© Copyright 2012 Hewlett-Packard Development Company, L.P. The information contained herein is subject to change without notice.
App cache is a new way to control browser
Browser cache ā€“ offline data
cache

19

Ā© Copyright 2012 Hewlett-Packard Development Company, L.P. The information contained herein is subject to change without notice.
You can control how your application behave
Especially in mobile!

20

Ā© Copyright 2012 Hewlett-Packard Development Company, L.P. The information contained herein is subject to change without notice.
HTML5 components: Web
notifications

Ā© Copyright 2012 Hewlett-Packard Development Company, L.P. The information contained herein is subject to change without notice.
Web notification: alert your users
Currently is being used at Gmail
It is very easy to implement and we can change the graphic design.

22

Ā© Copyright 2012 Hewlett-Packard Development Company, L.P. The information contained herein is subject to change without notice.
HTML5 components: Forms

Ā© Copyright 2012 Hewlett-Packard Development Company, L.P. The information contained herein is subject to change without notice.
Reminder: HTML4 form elements
Standard form element that being implemented along with the browser
In HTML4 we had mainly four form items:
ā€¢
ā€¢

Input (including password and text area) :
Select list:

ā€¢

Radio buttons:

ā€¢

Checkbox:

24

Ā© Copyright 2012 Hewlett-Packard Development Company, L.P. The information contained herein is subject to change without notice.
HTML5 form elements
New and exciting form elements in addition to the old ones
No need to re-invent the wheel ā€“ use the native elements!
http://jsfiddle.net/barzik/E426P/

25

Ā© Copyright 2012 Hewlett-Packard Development Company, L.P. The information contained herein is subject to change without notice.
Form elements in mobile

26

Ā© Copyright 2012 Hewlett-Packard Development Company, L.P. The information contained herein is subject to change without notice.
Custom Error messages in forms
HTML5 allows us native implementation of validation
It can be redesigned. But should we do it?
http://www.internet-israel.com/?p=3753

27

Ā© Copyright 2012 Hewlett-Packard Development Company, L.P. The information contained herein is subject to change without notice.
And it is still on development
New features are being added!

http://jsfiddle.net/barzik/2HcFG/

28

Ā© Copyright 2012 Hewlett-Packard Development Company, L.P. The information contained herein is subject to change without notice.
HTML5 components: Canvas &
SVG

Ā© Copyright 2012 Hewlett-Packard Development Company, L.P. The information contained herein is subject to change without notice.
HTML5 allows us to draw & create animations
Live & Native support on all browsers.
Canvas ā€“ classic graphics, no vector
SVG ā€“ Vector based graphic
Both have an API very similar to flash.

30

Ā© Copyright 2012 Hewlett-Packard Development Company, L.P. The information contained herein is subject to change without notice.
HTML5 components: Web
applications components

Ā© Copyright 2012 Hewlett-Packard Development Company, L.P. The information contained herein is subject to change without notice.
Full screen API
Lets take control on all of the screen
It is mainly for web application and not web sites (but it is really cool)
http://davidwalsh.name/demo/fullscreen.php

32

Ā© Copyright 2012 Hewlett-Packard Development Company, L.P. The information contained herein is subject to change without notice.
Native web application status
Use native HTML5 indicators for web application
<meter min="0" max="100" low="40" high="90" optimum="100" value="91">A+</meter>
<progress>working...</progress>
<progress value="75" max="100">3/4 complete</progress>

33

Ā© Copyright 2012 Hewlett-Packard Development Company, L.P. The information contained herein is subject to change without notice.
Thank you

Ā© Copyright 2012 Hewlett-Packard Development Company, L.P. The information contained herein is subject to change without notice.

More Related Content

What's hot

How to outsource the pain of drupal translation to smartling from loparev
How to outsource the pain of drupal translation to smartling from loparevHow to outsource the pain of drupal translation to smartling from loparev
How to outsource the pain of drupal translation to smartling from loparev
Oleksii Bogush
Ā 
Drupalcamp Simpletest
Drupalcamp SimpletestDrupalcamp Simpletest
Drupalcamp Simpletest
lyricnz
Ā 

What's hot (20)

Midwest PHP 2017 DevOps For Small team
Midwest PHP 2017 DevOps For Small teamMidwest PHP 2017 DevOps For Small team
Midwest PHP 2017 DevOps For Small team
Ā 
Drone CI
Drone CIDrone CI
Drone CI
Ā 
Comparing Agile QA Approaches to End-to-End Testing
Comparing Agile QA Approaches to End-to-End TestingComparing Agile QA Approaches to End-to-End Testing
Comparing Agile QA Approaches to End-to-End Testing
Ā 
Matteo Manchi - React Native for multi-platform mobile applications - Codemot...
Matteo Manchi - React Native for multi-platform mobile applications - Codemot...Matteo Manchi - React Native for multi-platform mobile applications - Codemot...
Matteo Manchi - React Native for multi-platform mobile applications - Codemot...
Ā 
Continuous delivery - tools and techniques
Continuous delivery - tools and techniquesContinuous delivery - tools and techniques
Continuous delivery - tools and techniques
Ā 
Silverlight vs HTML5 - Lessons learned from the real world...
Silverlight vs HTML5 - Lessons learned from the real world...Silverlight vs HTML5 - Lessons learned from the real world...
Silverlight vs HTML5 - Lessons learned from the real world...
Ā 
What I learned teaching programming to 150 beginners
What I learned teaching programming to 150 beginnersWhat I learned teaching programming to 150 beginners
What I learned teaching programming to 150 beginners
Ā 
CI
CICI
CI
Ā 
How to outsource the pain of drupal translation to smartling from loparev
How to outsource the pain of drupal translation to smartling from loparevHow to outsource the pain of drupal translation to smartling from loparev
How to outsource the pain of drupal translation to smartling from loparev
Ā 
Drupalcamp Simpletest
Drupalcamp SimpletestDrupalcamp Simpletest
Drupalcamp Simpletest
Ā 
React native first impression
React native first impressionReact native first impression
React native first impression
Ā 
Testing as a container
Testing as a containerTesting as a container
Testing as a container
Ā 
Experiences building apps with React Native @DomCode 2016
Experiences building apps with React Native @DomCode 2016Experiences building apps with React Native @DomCode 2016
Experiences building apps with React Native @DomCode 2016
Ā 
Use groovy & grails in your spring boot projects
Use groovy & grails in your spring boot projectsUse groovy & grails in your spring boot projects
Use groovy & grails in your spring boot projects
Ā 
Continuous delivery of your legacy application
Continuous delivery of your legacy applicationContinuous delivery of your legacy application
Continuous delivery of your legacy application
Ā 
JavaScript All The Things
JavaScript All The ThingsJavaScript All The Things
JavaScript All The Things
Ā 
GR8Conf 2015 - Spring Boot and Groovy. What more do you need?
GR8Conf 2015 - Spring Boot and Groovy. What more do you need?GR8Conf 2015 - Spring Boot and Groovy. What more do you need?
GR8Conf 2015 - Spring Boot and Groovy. What more do you need?
Ā 
Alexey Kupriyanenko "Release Early, Often, Stable"
Alexey Kupriyanenko "Release Early, Often, Stable"Alexey Kupriyanenko "Release Early, Often, Stable"
Alexey Kupriyanenko "Release Early, Often, Stable"
Ā 
Drone Continuous Integration
Drone Continuous IntegrationDrone Continuous Integration
Drone Continuous Integration
Ā 
ITB2019 ColdBox APIs + VueJS - powering Mobile, Desktop and Web Apps with 1 V...
ITB2019 ColdBox APIs + VueJS - powering Mobile, Desktop and Web Apps with 1 V...ITB2019 ColdBox APIs + VueJS - powering Mobile, Desktop and Web Apps with 1 V...
ITB2019 ColdBox APIs + VueJS - powering Mobile, Desktop and Web Apps with 1 V...
Ā 

Similar to HTML5 for dummies

UMK Lecture 5 - HTML5 latest v7
UMK Lecture 5 - HTML5 latest v7UMK Lecture 5 - HTML5 latest v7
UMK Lecture 5 - HTML5 latest v7
Hisham Mat Hussin
Ā 
Html5 today
Html5 todayHtml5 today
Html5 today
Roy Yu
Ā 
Coming Up to Speed with XML Authoring in Adobe FrameMaker
Coming Up to Speed with XML Authoring in Adobe FrameMakerComing Up to Speed with XML Authoring in Adobe FrameMaker
Coming Up to Speed with XML Authoring in Adobe FrameMaker
dclsocialmedia
Ā 

Similar to HTML5 for dummies (20)

Basic web dveleopers terms for UX and graphic designers
Basic web dveleopers terms for UX and graphic designersBasic web dveleopers terms for UX and graphic designers
Basic web dveleopers terms for UX and graphic designers
Ā 
Introducing AppPulse
Introducing AppPulse Introducing AppPulse
Introducing AppPulse
Ā 
HPLN Web Performance Optimization - Liran tal
HPLN Web Performance Optimization - Liran talHPLN Web Performance Optimization - Liran tal
HPLN Web Performance Optimization - Liran tal
Ā 
Html5
Html5Html5
Html5
Ā 
Html 5 Features And Benefits
Html 5 Features And Benefits  Html 5 Features And Benefits
Html 5 Features And Benefits
Ā 
HTML5: An Introduction
HTML5: An IntroductionHTML5: An Introduction
HTML5: An Introduction
Ā 
Everything That You Need To Know About HTML5
Everything That You Need To Know About HTML5Everything That You Need To Know About HTML5
Everything That You Need To Know About HTML5
Ā 
HTML5
HTML5HTML5
HTML5
Ā 
UMK Lecture 5 - HTML5 latest v7
UMK Lecture 5 - HTML5 latest v7UMK Lecture 5 - HTML5 latest v7
UMK Lecture 5 - HTML5 latest v7
Ā 
INTRUDUCTION TO HTML 5
INTRUDUCTION TO HTML 5INTRUDUCTION TO HTML 5
INTRUDUCTION TO HTML 5
Ā 
HTML5 101
HTML5 101HTML5 101
HTML5 101
Ā 
Html5
Html5Html5
Html5
Ā 
Flex360 Milan 2008 - Flex & Webservices
Flex360 Milan 2008 - Flex & WebservicesFlex360 Milan 2008 - Flex & Webservices
Flex360 Milan 2008 - Flex & Webservices
Ā 
Why Embrace "Html5"?
Why Embrace "Html5"?Why Embrace "Html5"?
Why Embrace "Html5"?
Ā 
Html5 today
Html5 todayHtml5 today
Html5 today
Ā 
HTML5_3.ppt
HTML5_3.pptHTML5_3.ppt
HTML5_3.ppt
Ā 
Joomla @ Barcamp4(Feb 08 Pune)
Joomla @ Barcamp4(Feb 08 Pune)Joomla @ Barcamp4(Feb 08 Pune)
Joomla @ Barcamp4(Feb 08 Pune)
Ā 
Here comes html5
Here comes html5Here comes html5
Here comes html5
Ā 
Coming Up to Speed with XML Authoring in Adobe FrameMaker
Coming Up to Speed with XML Authoring in Adobe FrameMakerComing Up to Speed with XML Authoring in Adobe FrameMaker
Coming Up to Speed with XML Authoring in Adobe FrameMaker
Ā 
Top 10 major benefits of html 5
Top 10 major benefits of html 5Top 10 major benefits of html 5
Top 10 major benefits of html 5
Ā 

More from Ran Bar-Zik

More from Ran Bar-Zik (12)

How to track users
How to track usersHow to track users
How to track users
Ā 
7 deadly front end sins
7 deadly front end sins7 deadly front end sins
7 deadly front end sins
Ā 
Javascript static code analysis
Javascript static code analysisJavascript static code analysis
Javascript static code analysis
Ā 
Quality code in wordpress
Quality code in wordpressQuality code in wordpress
Quality code in wordpress
Ā 
How to get your first job at the Israeli high tech industry
How to get your first job at the Israeli high tech industryHow to get your first job at the Israeli high tech industry
How to get your first job at the Israeli high tech industry
Ā 
WordPress Security 101 for developers
WordPress Security 101 for developersWordPress Security 101 for developers
WordPress Security 101 for developers
Ā 
Javascript Security - Three main methods of defending your MEAN stack
Javascript Security - Three main methods of defending your MEAN stackJavascript Security - Three main methods of defending your MEAN stack
Javascript Security - Three main methods of defending your MEAN stack
Ā 
WordPress automation and CI
WordPress automation and CIWordPress automation and CI
WordPress automation and CI
Ā 
Drupal Security
Drupal SecurityDrupal Security
Drupal Security
Ā 
Presentation skills - course example
Presentation skills - course examplePresentation skills - course example
Presentation skills - course example
Ā 
HTML55 media api
HTML55 media apiHTML55 media api
HTML55 media api
Ā 
Features in Drupal 7/6
Features in Drupal 7/6Features in Drupal 7/6
Features in Drupal 7/6
Ā 

Recently uploaded

Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers:  A Deep Dive into Serverless Spatial Data and FMECloud Frontiers:  A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Safe Software
Ā 
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
?#DUbAI#??##{{(ā˜Žļø+971_581248768%)**%*]'#abortion pills for sale in dubai@
Ā 
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers:  A Deep Dive into Serverless Spatial Data and FMECloud Frontiers:  A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Safe Software
Ā 

Recently uploaded (20)

TrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data DiscoveryTrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
Ā 
Six Myths about Ontologies: The Basics of Formal Ontology
Six Myths about Ontologies: The Basics of Formal OntologySix Myths about Ontologies: The Basics of Formal Ontology
Six Myths about Ontologies: The Basics of Formal Ontology
Ā 
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Ā 
DEV meet-up UiPath Document Understanding May 7 2024 Amsterdam
DEV meet-up UiPath Document Understanding May 7 2024 AmsterdamDEV meet-up UiPath Document Understanding May 7 2024 Amsterdam
DEV meet-up UiPath Document Understanding May 7 2024 Amsterdam
Ā 
Boost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdfBoost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdf
Ā 
Apidays New York 2024 - APIs in 2030: The Risk of Technological Sleepwalk by ...
Apidays New York 2024 - APIs in 2030: The Risk of Technological Sleepwalk by ...Apidays New York 2024 - APIs in 2030: The Risk of Technological Sleepwalk by ...
Apidays New York 2024 - APIs in 2030: The Risk of Technological Sleepwalk by ...
Ā 
Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...
Ā 
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
Ā 
Apidays New York 2024 - Passkeys: Developing APIs to enable passwordless auth...
Apidays New York 2024 - Passkeys: Developing APIs to enable passwordless auth...Apidays New York 2024 - Passkeys: Developing APIs to enable passwordless auth...
Apidays New York 2024 - Passkeys: Developing APIs to enable passwordless auth...
Ā 
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost SavingRepurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
Ā 
Strategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a FresherStrategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a Fresher
Ā 
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers:  A Deep Dive into Serverless Spatial Data and FMECloud Frontiers:  A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Ā 
AWS Community Day CPH - Three problems of Terraform
AWS Community Day CPH - Three problems of TerraformAWS Community Day CPH - Three problems of Terraform
AWS Community Day CPH - Three problems of Terraform
Ā 
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot TakeoffStrategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Ā 
Emergent Methods: Multi-lingual narrative tracking in the news - real-time ex...
Emergent Methods: Multi-lingual narrative tracking in the news - real-time ex...Emergent Methods: Multi-lingual narrative tracking in the news - real-time ex...
Emergent Methods: Multi-lingual narrative tracking in the news - real-time ex...
Ā 
ICT role in 21st century education and its challenges
ICT role in 21st century education and its challengesICT role in 21st century education and its challenges
ICT role in 21st century education and its challenges
Ā 
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
Ā 
Corporate and higher education May webinar.pptx
Corporate and higher education May webinar.pptxCorporate and higher education May webinar.pptx
Corporate and higher education May webinar.pptx
Ā 
Biography Of Angeliki Cooney | Senior Vice President Life Sciences | Albany, ...
Biography Of Angeliki Cooney | Senior Vice President Life Sciences | Albany, ...Biography Of Angeliki Cooney | Senior Vice President Life Sciences | Albany, ...
Biography Of Angeliki Cooney | Senior Vice President Life Sciences | Albany, ...
Ā 
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers:  A Deep Dive into Serverless Spatial Data and FMECloud Frontiers:  A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Ā 

HTML5 for dummies

  • 1. Guide to HTML 5 Ran Bar-Zik PHPDrupal Developer 19.02.2014 Ā© Copyright 2012 Hewlett-Packard Development Company, L.P. The information contained herein is subject to change without notice.
  • 2. Who am I? Ran Bar-Zik, ā€¢ PHP developer at HP Software ā€¢ Working at hpln.hp.com ā€¢ More information at my personal site: internet-israel.com 2 Ā© Copyright 2012 Hewlett-Packard Development Company, L.P. The information contained herein is subject to change without notice.
  • 3. What is HTML5 Ā© Copyright 2012 Hewlett-Packard Development Company, L.P. The information contained herein is subject to change without notice.
  • 4. Letā€™s talk about HTML 4 HTML standards are standards HTML is Instructions for the browsers ā€¢ ā€¢ For example: take this string: <h1>HEADER</h1> and show it in large font. For example, take this string: <input type=ā€œtextā€ value=ā€œhelloā€ /> and show it like this: ā€¢ ā€¢ For example: allow CSS to change the basic design of the elements (HTML 3) The HTML standards are being defined by the W3C 4 Ā© Copyright 2012 Hewlett-Packard Development Company, L.P. The information contained herein is subject to change without notice.
  • 5. HTML4 was great, really It allowed us to create sophisticated, rich web sites 5 Ā© Copyright 2012 Hewlett-Packard Development Company, L.P. The information contained herein is subject to change without notice.
  • 6. HTML4 needed a lot of code And programmers hate a lot of code A lot of code means headache: 1. We need to maintain it. 2. We need to keep it updated with every version of browser. Yes IE ā€“ I am looking at you! 3. We need to QA it 4. We are lazy! 6 Ā© Copyright 2012 Hewlett-Packard Development Company, L.P. The information contained herein is subject to change without notice.
  • 7. HTML5 to the rescue! HTML5 allows us to do a lot of things, but with less code HTML5 is a new standard that tells the browsers to do a lot more For example, use this string in order to create a placeholer: In order to do it in HTML 4 we need to write a lot of JavaScript: 7 Ā© Copyright 2012 Hewlett-Packard Development Company, L.P. The information contained herein is subject to change without notice.
  • 8. Some mind blowing HTML5 demos Now I will amaze you! https://developer.mozilla.org/en-US/demos/detail/zen-photongarden/launch http://craftymind.com/factory/html5video/CanvasVideo.html [ff] http://www.clicktorelease.com/code/css3dclouds/ http://hompimpa.googlecode.com/svn/trunk/CSS3-Windows7-StartMenus/index.html 8 Ā© Copyright 2012 Hewlett-Packard Development Company, L.P. The information contained herein is subject to change without notice.
  • 9. HTML5 is more than way to save code It allow us to do things that we canā€™t do previously For example: 1. Cache control (no way to deal with it previously) and offline behavior. 2. Geo location (very hard and unreliable in the past). 3. A lot of nerdy things for programmers to drool about like promises in JS, web workers etc. it allows us to create faster, reliable and efficient code. 9 Ā© Copyright 2012 Hewlett-Packard Development Company, L.P. The information contained herein is subject to change without notice.
  • 10. The IE situation Ā© Copyright 2012 Hewlett-Packard Development Company, L.P. The information contained herein is subject to change without notice.
  • 11. The main problem with HTML5 Internet Explorer and other old browsers does not support it Even new versions of Internet Explorer sometimes does not support part of HTML5 Why? Because IE suck. Thatā€™s why. We have 3 ways to deal with it: 11 Ā© Copyright 2012 Hewlett-Packard Development Company, L.P. The information contained herein is subject to change without notice.
  • 12. Polyfills JavaScript file that fill the gap for old browsers Allowing new features on old browsers For example: allowing HTML5 form control on Internet Explorer 8 that does not support this feature. What is the problem? ā€¢ Performance ā€¢ Reliability ā€¢ Sometimes there is no polyfill. 12 Ā© Copyright 2012 Hewlett-Packard Development Company, L.P. The information contained herein is subject to change without notice.
  • 13. Fallbacks Allow alternative solution for browsers that does not have the feature For example: Showing Flash videos for browsers that does not support HTML5 videos. What is the problem? ā€¢ Very inefficient ā€¢ A lot of code ā€¢ Annoying 13 Ā© Copyright 2012 Hewlett-Packard Development Company, L.P. The information contained herein is subject to change without notice.
  • 14. Ignore old browsers And there is no problem at allā€¦ 14 Ā© Copyright 2012 Hewlett-Packard Development Company, L.P. The information contained herein is subject to change without notice.
  • 15. HTML5 components: Video & Audio Ā© Copyright 2012 Hewlett-Packard Development Company, L.P. The information contained herein is subject to change without notice.
  • 16. We donā€™t need no FLASH for that Video and Audio become native to application And you can do amazing things with that ā€“ natively! http://www.apple.com/html5/showcase/video/ http://www.internet-israel.com/?p=3835 16 Ā© Copyright 2012 Hewlett-Packard Development Company, L.P. The information contained herein is subject to change without notice.
  • 17. But why do we need it? Video was there long before HTML5 Flash video suck ā€¢ ā€¢ ā€¢ ā€¢ ā€¢ 17 It is slow, unreliable and dependent on flash plug in. It is not part of the page and it is very hard to control. Very hard to play with. Subtitles Not supported on mobile. Ā© Copyright 2012 Hewlett-Packard Development Company, L.P. The information contained herein is subject to change without notice.
  • 18. HTML5 components: Appcache Ā© Copyright 2012 Hewlett-Packard Development Company, L.P. The information contained herein is subject to change without notice.
  • 19. App cache is a new way to control browser Browser cache ā€“ offline data cache 19 Ā© Copyright 2012 Hewlett-Packard Development Company, L.P. The information contained herein is subject to change without notice.
  • 20. You can control how your application behave Especially in mobile! 20 Ā© Copyright 2012 Hewlett-Packard Development Company, L.P. The information contained herein is subject to change without notice.
  • 21. HTML5 components: Web notifications Ā© Copyright 2012 Hewlett-Packard Development Company, L.P. The information contained herein is subject to change without notice.
  • 22. Web notification: alert your users Currently is being used at Gmail It is very easy to implement and we can change the graphic design. 22 Ā© Copyright 2012 Hewlett-Packard Development Company, L.P. The information contained herein is subject to change without notice.
  • 23. HTML5 components: Forms Ā© Copyright 2012 Hewlett-Packard Development Company, L.P. The information contained herein is subject to change without notice.
  • 24. Reminder: HTML4 form elements Standard form element that being implemented along with the browser In HTML4 we had mainly four form items: ā€¢ ā€¢ Input (including password and text area) : Select list: ā€¢ Radio buttons: ā€¢ Checkbox: 24 Ā© Copyright 2012 Hewlett-Packard Development Company, L.P. The information contained herein is subject to change without notice.
  • 25. HTML5 form elements New and exciting form elements in addition to the old ones No need to re-invent the wheel ā€“ use the native elements! http://jsfiddle.net/barzik/E426P/ 25 Ā© Copyright 2012 Hewlett-Packard Development Company, L.P. The information contained herein is subject to change without notice.
  • 26. Form elements in mobile 26 Ā© Copyright 2012 Hewlett-Packard Development Company, L.P. The information contained herein is subject to change without notice.
  • 27. Custom Error messages in forms HTML5 allows us native implementation of validation It can be redesigned. But should we do it? http://www.internet-israel.com/?p=3753 27 Ā© Copyright 2012 Hewlett-Packard Development Company, L.P. The information contained herein is subject to change without notice.
  • 28. And it is still on development New features are being added! http://jsfiddle.net/barzik/2HcFG/ 28 Ā© Copyright 2012 Hewlett-Packard Development Company, L.P. The information contained herein is subject to change without notice.
  • 29. HTML5 components: Canvas & SVG Ā© Copyright 2012 Hewlett-Packard Development Company, L.P. The information contained herein is subject to change without notice.
  • 30. HTML5 allows us to draw & create animations Live & Native support on all browsers. Canvas ā€“ classic graphics, no vector SVG ā€“ Vector based graphic Both have an API very similar to flash. 30 Ā© Copyright 2012 Hewlett-Packard Development Company, L.P. The information contained herein is subject to change without notice.
  • 31. HTML5 components: Web applications components Ā© Copyright 2012 Hewlett-Packard Development Company, L.P. The information contained herein is subject to change without notice.
  • 32. Full screen API Lets take control on all of the screen It is mainly for web application and not web sites (but it is really cool) http://davidwalsh.name/demo/fullscreen.php 32 Ā© Copyright 2012 Hewlett-Packard Development Company, L.P. The information contained herein is subject to change without notice.
  • 33. Native web application status Use native HTML5 indicators for web application <meter min="0" max="100" low="40" high="90" optimum="100" value="91">A+</meter> <progress>working...</progress> <progress value="75" max="100">3/4 complete</progress> 33 Ā© Copyright 2012 Hewlett-Packard Development Company, L.P. The information contained herein is subject to change without notice.
  • 34. Thank you Ā© Copyright 2012 Hewlett-Packard Development Company, L.P. The information contained herein is subject to change without notice.