16 Jun 2007

HTML5

Tags:

W3 has presented us with some differences between the “old” HTML4 and the new HTML5, which is still under development. HTML5 brings a few new features aimed at some modern trends, such as web applications.

Here are some of the features I found interesting:

  • HTML5 is joining html and xhtml markup. Documents may be written in either HTML5 or XHTML5
  • It does not allow nesting of block and inline elements under the same element. So this is incorrect:
    <div>
        <span></span>
        <div></div>
    </div>
  • Some new elements are introduced, such as article, dialog, header, footer, time, … No more <div id="header">...</div>!
  • Input’s type attribute now has some additional options, such as email, url, date, …
  • Replace attribute is introduced, telling us what happens to form elements after the form has been submitted. Narrows some javascript down.
  • contextmenu global attribute has been added to allow a context menu personalization
  • Frames are gone. Iframes only.
  • getElementsByClassName() is added to the DOM
  • innerHTML is now considered a standard

I quite like where this is going. It brings to more semantic markup, which is good for project organisation and none-css capable browsers such as screen readers and text-only browsers.

HTML5 differences from HTML4 - see for yourself
HTML5 specifications

Leave a Reply