Some HTML5 knowledge points you should remember

Source: Internet
Author: User
Tags sessionstorage

Some HTML5 knowledge points you should remember

At the beginning, I started to learn HTML5 from w3school. It was just a simple introduction. Later I started to watch some videos of HTML5 + CSS3 connected to my brother, some simple demos have been made according to the video (you can contact me for the children's shoes you need, and you can also go to ~~~ online ~~~), I always felt that I was missing something. I started to buy books and read Tang junkai's HTML5 mobile Web Development Guide. Below are some simple knowledge points, only cainiao like me can take an eye out. If you are a beginner, do not go ~~~!!!

1:

HTML5-based mobile Web Applications

CanvasPlotting: Get the Dom element Canvas in HTML, call the Context object of the rendering Context, and draw the image using Js.

Multimedia: Video and Audio (Multimedia Video Format: Ogg MPEG4 WebM)

Local Storage: Stores data by providing key/value

Web Storage:

HTML5-based mobile Web Applications

CanvasPlotting: Get the Dom element Canvas in HTML, call the Context object of the rendering Context, and draw the image using Js.

Multimedia: Video and Audio (Multimedia Video Format: Ogg MPEG4 WebM)

Local Storage: Stores data by providing key/value

Web Storage: localStorage-data Storage with no time limit

SessionStorage-data storage for a session. When the user closes the browser window, the data will be deleted.

Web SQL Database: stores data in a way similar to a relational Database (which is already an obsolete standard). openDatabase transaction executeSql

 

Offline applications: When a browser that supports offline applications detects a list File (Manifest File) and any resource files in it, it downloads the corresponding resource files and caches them locally.

Use geographic location

Mobile Web Framework: JQuery Mobile based on jQuery pages, Sencha Touch Based on ExtJS architecture, and PhoneGap framework that can connect the channels between Web and Native. There are two development modes: jQuery Mobile and Sencha Touch)

LocalStorage-data storage with no time limit

SessionStorage-data storage for a session. When the user closes the browser window, the data will be deleted.

Web SQL Database: stores data in a way similar to a relational Database (which is already an obsolete standard). openDatabase transaction executeSql

 

Offline applications: When a browser that supports offline applications detects a list File (Manifest File) and any resource files in it, it downloads the corresponding resource files and caches them locally.

Use geographic location

Mobile Web Framework: JQuery Mobile based on jQuery pages, Sencha Touch Based on ExtJS architecture, and PhoneGap framework that can connect the channels between Web and Native. There are two development modes: jQuery Mobile and Sencha Touch)

 

2: some interesting new features in HTML5:

  • Canvas elements used for painting
  • Video and audio elements used for media playback
  • Better support for local offline storage
  • New special content elements, such as article, footer, header, nav, section
  • New Form controls, such as calendar, date, time, email, url, and search

3:

LocalStorage: permanently stored data is domain-safe. It is domain-based and can access localStorage data on all pages in the domain.

Note that the data stored using localStorage in Firefox cannot be read in The Chorme browser. Similarly, because the localStorage data is stored on the device, data stored by the same application on different devices is different. For example, Android data cannot be accessed by IOS.

Let's take a look at the Storage API: attribute length; Method: setItem, getItem, removeItem, and clear. Of course, you can also understand the meaning of the names. Here we will not repeat the specific writing methods here.

SessionStorage: the stored data cycle is only stored in the current window that stores it or the new window that is created in the current window. Once it is closed, the data is cleared and it undertakes the Storage interface, the usage is basically the same as that of localStorage.

Storage time listening: StorageEvent API: key, oldValue, newValue, url, StorageArea; Storage time can be registered using addEventListener for listening

 

I only write so much for the moment today, and will keep updating ing...

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.