Why to learn HTML5

Source: Internet
Author: User

In order to decrypt HTML5 and help stubborn development designers, I wrote here a list of the use of HTML5 several major reasons, I hope to help you!

The tenth major reason: ease of use

Two reasons make it easier to create a Web site using HTML5: semantically and Aria. New HTML tags like

Nineth major reason: video and audio support

Forget Flash and other third-party apps, let your video and audio access resources via HTML5 tags <video> and <audio>. Playing the media correctly has always been a very scary thing, you need to use <embed> and <object> tags, and for them to play correctly it must be given a lot of parameters. Your media tags will be very complex, with a lot of confusing code. and HTML5 video and audio tags basically see them as pictures: <video src= ""/>. But other parameters such as width and height or autoplay?   Don't worry, just want to define it like other HTML tags: <video src= "url" width= "640px" height= "380px" autoplay/>. In fact, the process is very simple, but our old browsers may not like our HTML5, and you need to add more code to get them to work correctly. But the code is much simpler than the <embed> and <object>.

The eighth big reason: Doctype

Yes, it's doctype, no more. Is it a very simple answer? There is no need to copy and paste a bunch of incomprehensible code, and there is no extra head tag. The big good news is that, in addition to simplicity, it works in every browser, even the infamous IE6.

The seventh big reason: clearer code

If you have a preference for simple, elegant, easy-to-read code, HTML5 is definitely a tailored thing for you. HTML5 allows you to write simple, clear and descriptive code. Code that conforms to semantics allows you to separate styles and content. Take a look at this typical simple Heaer code that has navigation:

<div id= "header" > 

Is it simple? But using HTML5 makes the code simpler and more meaningful:

 

Using HTML5 you can finally solve your div and its class definition problem by using the semantics HTML header tag to describe the content. You used to use a lot of div to define each page content area, but use the new <section>,<article>,

The big reason: smarter storage

The coolest feature in HTML5 is local storage. There is a bit of convergence like the older technology cookie and the client database.   It's better than Cooke. Because it supports multiple Windows stores, it has better security and performance and can be saved even after the browser is closed.   Because it's a client-side database, you don't have to worry about users deleting any cookies, and all the mainstream browsers support it. Local storage is good for many situations, and it is a HTML5 tool that does not require third-party plug-ins to implement. Being able to save data to a user's browser means you can simply create some application features such as saving user information, caching data, and loading the user's last application state.

The big reason: better interaction

We all like better interaction, and we all like the Dynamic Web site where users have feedback, and users can enjoy the interactive process.   The input <CANVAS>,HTML5 's paint tag allows you to do more interaction and animation, just as we use flash to achieve results. In addition to <CANVAS>,HTML5 also has a lot of APIs that allow you to create a better user experience and more dynamic Web applications. Here's a list:

    • Drag and Drop (DnD)
    • Offline Storage Database
    • Browser History Management
    • Document editing
    • Timed Media Playback

The fourth big reason: game development

Yes, you can use the HTML5 <canvas> development game. HTML5 offers a very great, mobile-friendly way to develop fun interactive games.   If you develop flash games, you will enjoy the development of HTML5 games. Script-tutorials currently offers 4 parts of the HTML5 game development tutorial, here's a look at the interesting games they've developed:

    • HTML5 Gaming Development Lesson One
    • HTML5 Gaming Development Lesson Two
    • HTML5 Gaming Development Lesson Three
    • HTML5 Gaming Development Lesson Four

The third major reason: Legacy and Cross-browser support

Your modern popular browsers support HTML5 (CHROME,FIREFOX,SAFARI,IE9 and Opera) and create HTML5 doctype all browsers, even if it's very old and very disgusting. Browsers like IE6 can be used. But because older browsers can recognize DOCTYPE does not mean it can handle HTML5 tags and functions. Fortunately, HTML5 has made development simpler and more browser-enabled, so older IE browsers can use the new elements by adding JavaScript code:

<!--[if Lt IE 9]> <script src= "Http://html5shiv.googlecode.com/svn/trunk/html5.js" ></script><! [endif]-->

Second biggest reason: move, move, or move

You can call it "intuition," but I think mobile technology will become more popular. I know, there are some very crazy guesses, and some of you may have thought of –mobile is a fashion! Mobile devices will occupy the world. More acceptance of mobile devices will grow very quickly. This means that more users will choose to use mobile devices to access websites or web apps. HTML5 is the most mobile development tool.   As Adobe announces the abandonment of mobile flash development, you will consider using HTML5 to develop WEBP applications. When a mobile browser fully supports HTML5, developing a mobile project will be as simple as designing a smaller touch display. Here are a lot of meta tags that allow you to optimize the move:

    • Viewport: Allows you to define viewport width and zoom settings;
    • Full Screen Browser: ISO-specified values allow Apple device full-screen mode display;
    • Home screen icons: Like a desktop collection, these icons can be used to add to the homepage of iOS and Android mobile devices.

The first big reason: it is the future, start using it!

The biggest reason you start using HTML5 today is because it's the future, don't fall behind! HTML5 will not go in every direction, but more elements have been adopted by many companies and are beginning to develop. HTML5 is actually more like HTML, it's not a new technology that requires you to learn again! If you develop XHTML strict, you are already developing HTML5.   Why not enjoy the HTML5 function more completely? You don't actually have any excuse not to accept HTML5. In fact, the only reason I use HTML5 is because it's written in simple, clear code. Other features I don't actually use. You might want to start using HTML5 writing code now, which can help you change the way you write your code and how you design it. Start writing web Apps with HTML5 code, perhaps the next mobile app or game app is developed with HTML5!

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.