ReadWriteWeb

5 Exciting Things to Look Forward to in HTML 5 - Page 3

Page:  «  Prev 1   2   3

4. The <canvas> element allows image scripting on the fly

Most people take in information more quickly and effectively through visuals. For example, between a table, numerical data, and a pie chart, the pie chart gives users a better feel for the scale and relationship of data (at least most of the time).

The downside of images is that they're static. If you create a pie chart using a traditional method (for example, with an image editor like Photoshop, or a graphing application like Excel), you wouldn't be able to adjust any data that changes without manually editing your graphics.

With the <canvas> element, you can take constantly changing (database-driven) data and apply it to a pie chart like the one above, as well as other types of 2D visuals (even a cat, if you're so inclined), via scripting.

The canvas API also allows users to interact with <canvas> elements. For example, you can write a script that responds to users' clicking on a particular section of the pie chart.

5. Users can edit and interact with sections of a web page

The section in the proposed HTML 5 specifications about User Interaction describes new ways of marking up interactive web pages. The contenteditable attribute (a boolean attribute to which you assign either true or false) allows you to indicate which parts of a web page users can change.

This can be useful for wiki-style websites, in which content is user-generated. Another use of the contenteditable attribute would be to create web page templates. You can allow certain regions of a web page to be open to content editing and lock other regions that shouldn't be changed. This gives users of your website who aren't proficient in HTML an opportunity to input content safely without affecting critical areas that should be handled by more knowledgeable users.

At the document level, you can make an entire page editable via the designMode attribute, which accepts two values: on or off.

In Sum

The proposed specifications are slated to reach W3C Candidate Recommendation status in 2012, but that doesn't mean you have to wait that long to start using some of the new things in HTML 5. A lot of modern browsers, for example, have already implemented the <canvas> element (including Mozilla Firefox, which has partially implemented it since version 1.5).

HTML 5 will redefine how web developers mark up content. It will provide a better way to describe the content displayed on a web page, enable more complex content types, improve media and web application support, and increase the interoperability of HTML documents.

Note that things are still under heavy development and are bound to change; many of the proposed improvements may be heavily revised in the next few years or not implemented at all.

There are a lot of exciting new features in HTML 5. Share your own favorites in the comments.

Further reading


About the author

Jacob Gube is a web developer/designer and author of Six Revisions, a blog on web development and design. If you want to connect with the author, you can follow him on Twitter.

Page:  «  Prev 1   2   3


ReadWriteWeb encourages comments, but please remember: Keep it nice, keep it clean, and avoid promotional comments. We do pre-moderate some comments with links. For more information, please read our full comment policy.
RWW SPONSORS



ReadWriteCloud - Sponsored by VMware and Intel






RWW PARTNERS
Recommended Story