SlideShare une entreprise Scribd logo
1  sur  39
HTML5 Programming
             Nam Ho
      KMS Technology
HTML5 won’t be ready until 2022!
Do I need to wait for
the specifications are complete?
Real-world browser support is what
             matters!
A desktop example




    http://www.pirateslovedaisies.com/
A mobile example




http://m.microsoft.com/windowsphone/en-us/demo/index.html
The current state of HTML5 support



      http://caniuse.com/
Why programming?
This presentation doesn’t cover
•   Semantics & Markups
•   HTML5 Forms
•   Web Workers
•   WebGL
•   CSS3
•   SVG
•   …
This presentation covers
•   Video
•   Canvas
•   WebSocket
•   Data Storage
•   Offline
•   FileSystem
•   Geolocation
Multimedia

These specifications defines the video/audio elements with all the available
methods, attributes and events. Through the new APIs you can access, control
and manipulate timeline data and network states of the files. With the coming
additions to the APIs you will be able to read and write raw data to audio files
(Audio Data API) or manipulate captions in videos (Timed Track API).
Video
• Native video
• Video tag
  – <video src=“light.ogv” controls autoplay />

• Formats
  – .mp4 = H.264 + AAC
  – .ogg/.ogv = Theora + Vorbis
  – .webm = VP8 + Vorbis
• Legacy browser fallback
Audio
• Native audio
• Audio tag
  – <audio src=“hello.ogg” controls />
• Formats
  – .ogg/.oga
  – .mp3
  – .wav
  – .aac (Advanced Audio Coding)
• Legacy browser fallback
MIME types

Format   Attribute type   MIME type
.ogg     video/ogg        application/ogg
.mp4     video/mp4        video/mpeg
.webm    video/webm       video/webm
.mp3     audio/mp3        audio/mpeg
.wav     audio/wav        audio/wav
.aac     audio/aac        audio/aac
.mp4     audio/mp4        audio/mp4
Canvas

The canvas element provides scripts with a resolution-dependent bitmap
canvas, which can be used for rendering graphs, game graphics, or other visual
images on the fly.
Canvas
• Native drawing surface
• Canvas tag
  – <canvas id=“square” width=“10” height=“10” />

• JavaScript API for 2D drawing
WebSocket

To enable Web applications to maintain bidirectional communications with
server-side processes, this specification introduces the WebSocket interface.
WebSocket
• WebSocket object
• New protocol
  – ws://html5rocks.websocket.org/echo

• Establishing an open connection
  – Client and server can send data at any time
  – Realtime web application
WebSocket example
Web Storage

This specification introduces two related mechanisms, similar to HTTP session
cookies, for storing structured data on the client side.
Web storage
•   Avoiding HTTP overhead of cookies
•   Key-value pairs
•   Local storage
•   Session storage
•   Quota
    – Needing user confirmation if exceeding storage
      capability
Indexed Database

This specification defines APIs for a database of records holding simple values
and hierarchical objects. Each record consists of a key and some value.
Moreover, the database maintains indexes over records it stores. An application
developer directly uses an API to locate records either by their key or by using an
index. A query language can be layered on this API. An indexed database can be
implemented using a persistent B-tree data structure.
Indexed database
• Object based data store
• Asynchronous API
• Execute commands and open cursor inside
  transactions
Opening indexed database
Creating an Object Store
Storing data into Object Store
Querying data by cursor
Offline

In order to enable users to continue interacting with Web applications and
documents even when their network connection is unavailable — for
instance, because they are traveling outside of their ISP's coverage area —
authors can provide a manifest which lists the files that are needed for the Web
application to work offline and which causes the user's browser to keep a copy
of the files for use offline.
Application cache
• Cache resources locally
   – HTML, CSS, JavaScript, images, etc.
• Use a manifest file to specify resources in order to
  cache
• Download caching resources in a transaction
• window.applicationCache
• Add manifest attribute to html tag
   – manifest=“example.appcache”
• MIME type
   – text/cache-manifest appcache
• Clear cache: chrome://appcache-internals/
Manifest file
CACHE MANIFEST
#v1.0.0

CACHE
index.html
style.css
Scripts/main.js
images/logo.png

FALLBACK
time.js fallback_time.js
Updating to new version
FileSystem

This specification defines an API to navigate file system hierarchies, and defines
a means by which a browser may expose sandboxed sections of a user's local
file system to web applications.
File system
• Sandboxed environment
• Allow create/edit/delete files and directories
Geolocation

The Geolocation API defines a high-level interface to location information
associated only with the device hosting the implementation, such as latitude
and longitude. The API itself is agnostic of the underlying location information
sources. Common sources of location information include Global Positioning
System (GPS) and location inferred from network signals such as IP address,
RFID, WiFi and Bluetooth MAC addresses, and GSM/CDMA cell IDs, as well as
user input. No guarantee is given that the API returns the device's actual
location.
Geolocation
• Allow users to share their location for location-aware services
    – Application >> Browser >> 3rd services such as Skyhook or Google

• Privacy
    – Users are asked to share their location

• navigator.geolocation
    – getCurrentPosition
    – watchPosition

• Location metadata
    – latitude/longtitude/altitude
    – accuracy/altitudeAccuracy
    – heading/speed
Resources
• HTML5 rocks
  – http://www.html5rocks.com/en/
• Modernizr
  – http://www.modernizr.com/
• Mobile HTML5
  – http://mobilehtml5.org/
• Source code
  – http://bit.ly/tZ6eBn
Q & A

Email: namho@kms-technology.com
Twitter: @hotrannam
Thank you for joining!

Contenu connexe

Tendances

FluentD for end to end monitoring
FluentD for end to end monitoringFluentD for end to end monitoring
FluentD for end to end monitoringPhil Wilkins
 
Fluentd v1.0 in a nutshell
Fluentd v1.0 in a nutshellFluentd v1.0 in a nutshell
Fluentd v1.0 in a nutshellN Masahiro
 
Life of an Fluentd event
Life of an Fluentd eventLife of an Fluentd event
Life of an Fluentd eventKiyoto Tamura
 
Learn ELK in docker
Learn ELK in dockerLearn ELK in docker
Learn ELK in dockerLarry Cai
 
Attack monitoring using ElasticSearch Logstash and Kibana
Attack monitoring using ElasticSearch Logstash and KibanaAttack monitoring using ElasticSearch Logstash and Kibana
Attack monitoring using ElasticSearch Logstash and KibanaPrajal Kulkarni
 
Dive into Fluentd plugin v0.12
Dive into Fluentd plugin v0.12Dive into Fluentd plugin v0.12
Dive into Fluentd plugin v0.12N Masahiro
 
Logstash: Get to know your logs
Logstash: Get to know your logsLogstash: Get to know your logs
Logstash: Get to know your logsSmartLogic
 
From zero to hero - Easy log centralization with Logstash and Elasticsearch
From zero to hero - Easy log centralization with Logstash and ElasticsearchFrom zero to hero - Easy log centralization with Logstash and Elasticsearch
From zero to hero - Easy log centralization with Logstash and ElasticsearchRafał Kuć
 
The ELK Stack - Get to Know Logs
The ELK Stack - Get to Know LogsThe ELK Stack - Get to Know Logs
The ELK Stack - Get to Know LogsGlobalLogic Ukraine
 
Fluentd v1 and future at techtalk
Fluentd v1 and future at techtalkFluentd v1 and future at techtalk
Fluentd v1 and future at techtalkN Masahiro
 
MySQL Slow Query log Monitoring using Beats & ELK
MySQL Slow Query log Monitoring using Beats & ELKMySQL Slow Query log Monitoring using Beats & ELK
MySQL Slow Query log Monitoring using Beats & ELKYoungHeon (Roy) Kim
 
Fluentd Overview, Now and Then
Fluentd Overview, Now and ThenFluentd Overview, Now and Then
Fluentd Overview, Now and ThenSATOSHI TAGOMORI
 
The State of Logging on Docker
The State of Logging on DockerThe State of Logging on Docker
The State of Logging on DockerTrevor Parsons
 
Logging logs with Logstash - Devops MK 10-02-2016
Logging logs with Logstash - Devops MK 10-02-2016Logging logs with Logstash - Devops MK 10-02-2016
Logging logs with Logstash - Devops MK 10-02-2016Steve Howe
 

Tendances (20)

Fluentd vs. Logstash for OpenStack Log Management
Fluentd vs. Logstash for OpenStack Log ManagementFluentd vs. Logstash for OpenStack Log Management
Fluentd vs. Logstash for OpenStack Log Management
 
Fluentd and AWS at classmethod
Fluentd and AWS at classmethodFluentd and AWS at classmethod
Fluentd and AWS at classmethod
 
FluentD for end to end monitoring
FluentD for end to end monitoringFluentD for end to end monitoring
FluentD for end to end monitoring
 
Fluentd v1.0 in a nutshell
Fluentd v1.0 in a nutshellFluentd v1.0 in a nutshell
Fluentd v1.0 in a nutshell
 
Life of an Fluentd event
Life of an Fluentd eventLife of an Fluentd event
Life of an Fluentd event
 
Logging & Docker - Season 2
Logging & Docker - Season 2Logging & Docker - Season 2
Logging & Docker - Season 2
 
Learn ELK in docker
Learn ELK in dockerLearn ELK in docker
Learn ELK in docker
 
Attack monitoring using ElasticSearch Logstash and Kibana
Attack monitoring using ElasticSearch Logstash and KibanaAttack monitoring using ElasticSearch Logstash and Kibana
Attack monitoring using ElasticSearch Logstash and Kibana
 
Dive into Fluentd plugin v0.12
Dive into Fluentd plugin v0.12Dive into Fluentd plugin v0.12
Dive into Fluentd plugin v0.12
 
Logstash: Get to know your logs
Logstash: Get to know your logsLogstash: Get to know your logs
Logstash: Get to know your logs
 
From zero to hero - Easy log centralization with Logstash and Elasticsearch
From zero to hero - Easy log centralization with Logstash and ElasticsearchFrom zero to hero - Easy log centralization with Logstash and Elasticsearch
From zero to hero - Easy log centralization with Logstash and Elasticsearch
 
The ELK Stack - Get to Know Logs
The ELK Stack - Get to Know LogsThe ELK Stack - Get to Know Logs
The ELK Stack - Get to Know Logs
 
Fluentd v1 and future at techtalk
Fluentd v1 and future at techtalkFluentd v1 and future at techtalk
Fluentd v1 and future at techtalk
 
Fluentd v1 and Roadmap
Fluentd v1 and RoadmapFluentd v1 and Roadmap
Fluentd v1 and Roadmap
 
MySQL Slow Query log Monitoring using Beats & ELK
MySQL Slow Query log Monitoring using Beats & ELKMySQL Slow Query log Monitoring using Beats & ELK
MySQL Slow Query log Monitoring using Beats & ELK
 
Fluentd Overview, Now and Then
Fluentd Overview, Now and ThenFluentd Overview, Now and Then
Fluentd Overview, Now and Then
 
The State of Logging on Docker
The State of Logging on DockerThe State of Logging on Docker
The State of Logging on Docker
 
Logstash
LogstashLogstash
Logstash
 
Logging logs with Logstash - Devops MK 10-02-2016
Logging logs with Logstash - Devops MK 10-02-2016Logging logs with Logstash - Devops MK 10-02-2016
Logging logs with Logstash - Devops MK 10-02-2016
 
elk_stack_alexander_szalonnas
elk_stack_alexander_szalonnaselk_stack_alexander_szalonnas
elk_stack_alexander_szalonnas
 

En vedette

Multi tenancy
Multi tenancyMulti tenancy
Multi tenancyhotrannam
 
Ruby on Rails 3
Ruby on Rails 3Ruby on Rails 3
Ruby on Rails 3hotrannam
 
Applied Redis
Applied RedisApplied Redis
Applied Redishotrannam
 
jQuery plugins - templates, data link, globalization
jQuery plugins - templates, data link, globalizationjQuery plugins - templates, data link, globalization
jQuery plugins - templates, data link, globalizationhotrannam
 
Microsoft Windows Azure in short
Microsoft Windows Azure in shortMicrosoft Windows Azure in short
Microsoft Windows Azure in shortDuy Lâm
 
Building real time web apps with Meteor
Building real time web apps with MeteorBuilding real time web apps with Meteor
Building real time web apps with Meteorhotrannam
 

En vedette (6)

Multi tenancy
Multi tenancyMulti tenancy
Multi tenancy
 
Ruby on Rails 3
Ruby on Rails 3Ruby on Rails 3
Ruby on Rails 3
 
Applied Redis
Applied RedisApplied Redis
Applied Redis
 
jQuery plugins - templates, data link, globalization
jQuery plugins - templates, data link, globalizationjQuery plugins - templates, data link, globalization
jQuery plugins - templates, data link, globalization
 
Microsoft Windows Azure in short
Microsoft Windows Azure in shortMicrosoft Windows Azure in short
Microsoft Windows Azure in short
 
Building real time web apps with Meteor
Building real time web apps with MeteorBuilding real time web apps with Meteor
Building real time web apps with Meteor
 

Similaire à HTML5 Programming

Evolution Of The Web Platform & Browser Security
Evolution Of The Web Platform & Browser SecurityEvolution Of The Web Platform & Browser Security
Evolution Of The Web Platform & Browser SecuritySanjeev Verma, PhD
 
HTML5 and CSS3 refresher
HTML5 and CSS3 refresherHTML5 and CSS3 refresher
HTML5 and CSS3 refresherIvano Malavolta
 
05.m3 cms list-ofwebserver
05.m3 cms list-ofwebserver05.m3 cms list-ofwebserver
05.m3 cms list-ofwebservertarensi
 
HTML5: An Overview
HTML5: An OverviewHTML5: An Overview
HTML5: An OverviewNagendra Um
 
The History and Status of Web Crypto API (2012)
The History and Status of Web Crypto API (2012)The History and Status of Web Crypto API (2012)
The History and Status of Web Crypto API (2012)Channy Yun
 
WSO2 Intro Webinar - Scale your business with the cloud enabled WSO2 Applica...
WSO2 Intro Webinar -  Scale your business with the cloud enabled WSO2 Applica...WSO2 Intro Webinar -  Scale your business with the cloud enabled WSO2 Applica...
WSO2 Intro Webinar - Scale your business with the cloud enabled WSO2 Applica...WSO2
 
Cloudy rec citygridlosangeleshackathon (1)
Cloudy rec citygridlosangeleshackathon (1)Cloudy rec citygridlosangeleshackathon (1)
Cloudy rec citygridlosangeleshackathon (1)Kin Lane
 
Alfresco Coding mit dem Alfresco SDK (auf Englisch) - Julien Bruinaud, Techni...
Alfresco Coding mit dem Alfresco SDK (auf Englisch) - Julien Bruinaud, Techni...Alfresco Coding mit dem Alfresco SDK (auf Englisch) - Julien Bruinaud, Techni...
Alfresco Coding mit dem Alfresco SDK (auf Englisch) - Julien Bruinaud, Techni...Nicole Szigeti
 
HTML5 & CSS3 refresher for mobile apps
HTML5 & CSS3 refresher for mobile appsHTML5 & CSS3 refresher for mobile apps
HTML5 & CSS3 refresher for mobile appsIvano Malavolta
 
Developer’s intro to the alfresco platform
Developer’s intro to the alfresco platformDeveloper’s intro to the alfresco platform
Developer’s intro to the alfresco platformAlfresco Software
 
HTML5 features & JavaScript APIs
HTML5 features & JavaScript APIsHTML5 features & JavaScript APIs
HTML5 features & JavaScript APIsFisnik Doko
 
IoT Physical Servers and Cloud Offerings.pdf
IoT Physical Servers and Cloud Offerings.pdfIoT Physical Servers and Cloud Offerings.pdf
IoT Physical Servers and Cloud Offerings.pdfGVNSK Sravya
 

Similaire à HTML5 Programming (20)

Evolution Of The Web Platform & Browser Security
Evolution Of The Web Platform & Browser SecurityEvolution Of The Web Platform & Browser Security
Evolution Of The Web Platform & Browser Security
 
HTML5 and CSS3 refresher
HTML5 and CSS3 refresherHTML5 and CSS3 refresher
HTML5 and CSS3 refresher
 
Basics of the Web Platform
Basics of the Web PlatformBasics of the Web Platform
Basics of the Web Platform
 
05.m3 cms list-ofwebserver
05.m3 cms list-ofwebserver05.m3 cms list-ofwebserver
05.m3 cms list-ofwebserver
 
Html5
Html5Html5
Html5
 
Real time web apps
Real time web appsReal time web apps
Real time web apps
 
Building SPA’s (Single Page App) with Backbone.js
Building SPA’s (Single Page App) with Backbone.jsBuilding SPA’s (Single Page App) with Backbone.js
Building SPA’s (Single Page App) with Backbone.js
 
Firefox OS Weekend
Firefox OS WeekendFirefox OS Weekend
Firefox OS Weekend
 
HTML5: An Overview
HTML5: An OverviewHTML5: An Overview
HTML5: An Overview
 
The History and Status of Web Crypto API (2012)
The History and Status of Web Crypto API (2012)The History and Status of Web Crypto API (2012)
The History and Status of Web Crypto API (2012)
 
HTML5 Refresher
HTML5 RefresherHTML5 Refresher
HTML5 Refresher
 
WSO2 Intro Webinar - Scale your business with the cloud enabled WSO2 Applica...
WSO2 Intro Webinar -  Scale your business with the cloud enabled WSO2 Applica...WSO2 Intro Webinar -  Scale your business with the cloud enabled WSO2 Applica...
WSO2 Intro Webinar - Scale your business with the cloud enabled WSO2 Applica...
 
Cloudy rec citygridlosangeleshackathon (1)
Cloudy rec citygridlosangeleshackathon (1)Cloudy rec citygridlosangeleshackathon (1)
Cloudy rec citygridlosangeleshackathon (1)
 
Alfresco Coding mit dem Alfresco SDK (auf Englisch) - Julien Bruinaud, Techni...
Alfresco Coding mit dem Alfresco SDK (auf Englisch) - Julien Bruinaud, Techni...Alfresco Coding mit dem Alfresco SDK (auf Englisch) - Julien Bruinaud, Techni...
Alfresco Coding mit dem Alfresco SDK (auf Englisch) - Julien Bruinaud, Techni...
 
Prueba ppt
Prueba pptPrueba ppt
Prueba ppt
 
Html5v1
Html5v1Html5v1
Html5v1
 
HTML5 & CSS3 refresher for mobile apps
HTML5 & CSS3 refresher for mobile appsHTML5 & CSS3 refresher for mobile apps
HTML5 & CSS3 refresher for mobile apps
 
Developer’s intro to the alfresco platform
Developer’s intro to the alfresco platformDeveloper’s intro to the alfresco platform
Developer’s intro to the alfresco platform
 
HTML5 features & JavaScript APIs
HTML5 features & JavaScript APIsHTML5 features & JavaScript APIs
HTML5 features & JavaScript APIs
 
IoT Physical Servers and Cloud Offerings.pdf
IoT Physical Servers and Cloud Offerings.pdfIoT Physical Servers and Cloud Offerings.pdf
IoT Physical Servers and Cloud Offerings.pdf
 

Dernier

Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...Miguel Araújo
 
Injustice - Developers Among Us (SciFiDevCon 2024)
Injustice - Developers Among Us (SciFiDevCon 2024)Injustice - Developers Among Us (SciFiDevCon 2024)
Injustice - Developers Among Us (SciFiDevCon 2024)Allon Mureinik
 
CNv6 Instructor Chapter 6 Quality of Service
CNv6 Instructor Chapter 6 Quality of ServiceCNv6 Instructor Chapter 6 Quality of Service
CNv6 Instructor Chapter 6 Quality of Servicegiselly40
 
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptxHampshireHUG
 
2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...Martijn de Jong
 
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
 
Kalyanpur ) Call Girls in Lucknow Finest Escorts Service 🍸 8923113531 🎰 Avail...
Kalyanpur ) Call Girls in Lucknow Finest Escorts Service 🍸 8923113531 🎰 Avail...Kalyanpur ) Call Girls in Lucknow Finest Escorts Service 🍸 8923113531 🎰 Avail...
Kalyanpur ) Call Girls in Lucknow Finest Escorts Service 🍸 8923113531 🎰 Avail...gurkirankumar98700
 
Salesforce Community Group Quito, Salesforce 101
Salesforce Community Group Quito, Salesforce 101Salesforce Community Group Quito, Salesforce 101
Salesforce Community Group Quito, Salesforce 101Paola De la Torre
 
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdfThe Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdfEnterprise Knowledge
 
Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024The Digital Insurer
 
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
 
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
 
Handwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed textsHandwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed textsMaria Levchenko
 
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
 
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure service
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure serviceWhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure service
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure servicePooja Nehwal
 
Breaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path MountBreaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path MountPuma Security, LLC
 
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...Neo4j
 
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
 
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
 
Unblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen FramesUnblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen FramesSinan KOZAK
 

Dernier (20)

Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
 
Injustice - Developers Among Us (SciFiDevCon 2024)
Injustice - Developers Among Us (SciFiDevCon 2024)Injustice - Developers Among Us (SciFiDevCon 2024)
Injustice - Developers Among Us (SciFiDevCon 2024)
 
CNv6 Instructor Chapter 6 Quality of Service
CNv6 Instructor Chapter 6 Quality of ServiceCNv6 Instructor Chapter 6 Quality of Service
CNv6 Instructor Chapter 6 Quality of Service
 
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
 
2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...
 
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
 
Kalyanpur ) Call Girls in Lucknow Finest Escorts Service 🍸 8923113531 🎰 Avail...
Kalyanpur ) Call Girls in Lucknow Finest Escorts Service 🍸 8923113531 🎰 Avail...Kalyanpur ) Call Girls in Lucknow Finest Escorts Service 🍸 8923113531 🎰 Avail...
Kalyanpur ) Call Girls in Lucknow Finest Escorts Service 🍸 8923113531 🎰 Avail...
 
Salesforce Community Group Quito, Salesforce 101
Salesforce Community Group Quito, Salesforce 101Salesforce Community Group Quito, Salesforce 101
Salesforce Community Group Quito, Salesforce 101
 
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdfThe Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
 
Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024
 
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
 
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...
 
Handwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed textsHandwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed texts
 
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
 
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure service
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure serviceWhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure service
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure service
 
Breaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path MountBreaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path Mount
 
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...
 
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
 
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
 
Unblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen FramesUnblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen Frames
 

HTML5 Programming

  • 1. HTML5 Programming Nam Ho KMS Technology
  • 2. HTML5 won’t be ready until 2022!
  • 3. Do I need to wait for the specifications are complete?
  • 4. Real-world browser support is what matters!
  • 5. A desktop example http://www.pirateslovedaisies.com/
  • 7. The current state of HTML5 support http://caniuse.com/
  • 8.
  • 10. This presentation doesn’t cover • Semantics & Markups • HTML5 Forms • Web Workers • WebGL • CSS3 • SVG • …
  • 11. This presentation covers • Video • Canvas • WebSocket • Data Storage • Offline • FileSystem • Geolocation
  • 12. Multimedia These specifications defines the video/audio elements with all the available methods, attributes and events. Through the new APIs you can access, control and manipulate timeline data and network states of the files. With the coming additions to the APIs you will be able to read and write raw data to audio files (Audio Data API) or manipulate captions in videos (Timed Track API).
  • 13. Video • Native video • Video tag – <video src=“light.ogv” controls autoplay /> • Formats – .mp4 = H.264 + AAC – .ogg/.ogv = Theora + Vorbis – .webm = VP8 + Vorbis • Legacy browser fallback
  • 14. Audio • Native audio • Audio tag – <audio src=“hello.ogg” controls /> • Formats – .ogg/.oga – .mp3 – .wav – .aac (Advanced Audio Coding) • Legacy browser fallback
  • 15. MIME types Format Attribute type MIME type .ogg video/ogg application/ogg .mp4 video/mp4 video/mpeg .webm video/webm video/webm .mp3 audio/mp3 audio/mpeg .wav audio/wav audio/wav .aac audio/aac audio/aac .mp4 audio/mp4 audio/mp4
  • 16. Canvas The canvas element provides scripts with a resolution-dependent bitmap canvas, which can be used for rendering graphs, game graphics, or other visual images on the fly.
  • 17. Canvas • Native drawing surface • Canvas tag – <canvas id=“square” width=“10” height=“10” /> • JavaScript API for 2D drawing
  • 18. WebSocket To enable Web applications to maintain bidirectional communications with server-side processes, this specification introduces the WebSocket interface.
  • 19. WebSocket • WebSocket object • New protocol – ws://html5rocks.websocket.org/echo • Establishing an open connection – Client and server can send data at any time – Realtime web application
  • 21. Web Storage This specification introduces two related mechanisms, similar to HTTP session cookies, for storing structured data on the client side.
  • 22. Web storage • Avoiding HTTP overhead of cookies • Key-value pairs • Local storage • Session storage • Quota – Needing user confirmation if exceeding storage capability
  • 23. Indexed Database This specification defines APIs for a database of records holding simple values and hierarchical objects. Each record consists of a key and some value. Moreover, the database maintains indexes over records it stores. An application developer directly uses an API to locate records either by their key or by using an index. A query language can be layered on this API. An indexed database can be implemented using a persistent B-tree data structure.
  • 24. Indexed database • Object based data store • Asynchronous API • Execute commands and open cursor inside transactions
  • 27. Storing data into Object Store
  • 29. Offline In order to enable users to continue interacting with Web applications and documents even when their network connection is unavailable — for instance, because they are traveling outside of their ISP's coverage area — authors can provide a manifest which lists the files that are needed for the Web application to work offline and which causes the user's browser to keep a copy of the files for use offline.
  • 30. Application cache • Cache resources locally – HTML, CSS, JavaScript, images, etc. • Use a manifest file to specify resources in order to cache • Download caching resources in a transaction • window.applicationCache • Add manifest attribute to html tag – manifest=“example.appcache” • MIME type – text/cache-manifest appcache • Clear cache: chrome://appcache-internals/
  • 32. Updating to new version
  • 33. FileSystem This specification defines an API to navigate file system hierarchies, and defines a means by which a browser may expose sandboxed sections of a user's local file system to web applications.
  • 34. File system • Sandboxed environment • Allow create/edit/delete files and directories
  • 35. Geolocation The Geolocation API defines a high-level interface to location information associated only with the device hosting the implementation, such as latitude and longitude. The API itself is agnostic of the underlying location information sources. Common sources of location information include Global Positioning System (GPS) and location inferred from network signals such as IP address, RFID, WiFi and Bluetooth MAC addresses, and GSM/CDMA cell IDs, as well as user input. No guarantee is given that the API returns the device's actual location.
  • 36. Geolocation • Allow users to share their location for location-aware services – Application >> Browser >> 3rd services such as Skyhook or Google • Privacy – Users are asked to share their location • navigator.geolocation – getCurrentPosition – watchPosition • Location metadata – latitude/longtitude/altitude – accuracy/altitudeAccuracy – heading/speed
  • 37. Resources • HTML5 rocks – http://www.html5rocks.com/en/ • Modernizr – http://www.modernizr.com/ • Mobile HTML5 – http://mobilehtml5.org/ • Source code – http://bit.ly/tZ6eBn
  • 38. Q & A Email: namho@kms-technology.com Twitter: @hotrannam
  • 39. Thank you for joining!

Notes de l'éditeur

  1. http://introducinghtml5.com/examples/ch07/time/http://ie.microsoft.com/testdrive/HTML5/KidsBook/