3 ms·
I'm constantly confused by 'HTML5', because many of these examples look more like Javascript than a markup language. I've used HTML5 a bit here and there, but j
by tibbon 16y ago
I'm constantly confused by 'HTML5', because many of these examples look more like Javascript than a markup language. I've used HTML5 a bit here and there, but just as the next version of XHTML, using things like the <article> tag.
- joelanman 16y agoThe examples are all JavaScript code to detect support for new html5 tags/features. If the client doesn't support one, for example <video>, you can fail gracefully and maybe offer an alternative piece of content eg Flash.
- Sidnicious 16y agoHTML5 is a set of enhancements to HTML and to the JavaScript DOM API. This page is actually a great summary of HTML5 features that developers are likely to care about. For instance: - The <audio> and <video> elements - The <canvas> element - Form validation (without JavaScript!) - New <input>s for data like dates, times, numbers, ranges, and colors, for which the UA can provide OS-native controls - An API for cross-domain communication between windows - An API for providing and accepting drag and drop within, between, into, and out of browser windows - Web Workers for computation in the background - Web Sockets for efficient communication with your server - A persistent local database ...and much more! This page focuses on detecting support for many HTML5 features in JavaScript, so that a developer could, say, swap in their own datepicker if the browser doesn't offer one.