There are many new elements. I provide a comprehensive list of these in the weblog part of this site. I only provide direct access to a few examples below.
HTML5 element examples
Examples of many HTML5 elements
New form elements
Some of the new form elements are provided in the example below. These include:
- [but are not limited to]
- new input types (try this page out on an Android phone and note what happens when you choose a given field). These types include: email, url, number, and tel.
- new attribute - placeholder
- Example 1 - new input elements and placeholder attribute.
- Example 2 - new input elements and required attribute.
- Example 3 - new input elements and autocomplete attribute.
- Example 4 - new input elements and autofocus attribute.
- Example 5 - datalist element.
- Example 6 - majority of new input element type attribute examples (Opera is best browser to view implementation of these attributes).
Example local storage
- Example 1 - example of setting, reading, and removing information in local storage. Your browser must support HTML5 for this to work.
Example audio inclusion
- Example 1 - graceful degradation with <audio> element.
Example video inclusion
- Example 1 - graceful degradation with <video> element.
- Note the Open WebM video format should be in the next release of Chrome, Firefox, and Opera.
- HTML5video.org has a number of useful ideas
- HTML5 video for everybody (shows code necessary to run video in most browsers today)
Example HTML5 Drag and Drop
- Example 1 - from Adobe Labs (obtained via Widget browser). In order for this to work in most current browsers, a fair amount of code (JS and CSS) was employed by Adobe developers.