This blog include maximum details about html4 and html5 so that we can recall all the features / difference between HTML4 and HTML5. I am trying to keep things simple so that once can understand, presuming that you have little knowledge about html4 and html5.
1. HTML5 DocType and Charset.
UP HTML4 there are multiple type of document type declarations where exists (Strict, Transitional, Frameset) and was used as per the need. Which was very difficult to understand and remember as well. HTML5 has made it easy, no need to specify dtd urls. Similarly Meta tag definition is optimized, please see the syntax bellow.
1. < !doctype html> 2.
2. video and audio embed tags in HTML 5.
Audio and video tag syntax are very simple one, please refer the bellow.
HTML5 has strong support for media tags. Other than audio and video tags, it also supports following tags:
3. canvas Element in HTML 5
4. different types of storage in HTML5
HTML5 has capability to store data locally. Previously, it was done via cookies. The exciting thing about this storage is that it’s fast and secure.
There are two different objects which can be used to store data locally
– localStorage: Object stores data for a longer period of time even if the browser is closed. It helps to optimize the performance, reuse the data for analysis e.g.Shopping cart website can do this
– sessionStorage: session storage object stores data for a specific session. e.g. Products added by user in shopping cart.
5. What are the new Form Elements introduced in HTML 5?
HTML5 has number of new form elements few of them are follows
6. What are the deprecated Elements in HTML5 from HTML4?
Deprecated elements from HTML 4 to HTML 5 are as follow
7. What are the new APIs provided by HTML 5 standard?
HTML5 comes with number of new APIs. Few of them are as follows
Text Track API
Application Cache API
Data Transfer API
Constraint Validation API
History API and many more….
8. difference between HTML 5 Application Cache and regular HTML Browser Cache?
< !doctype html> .....