Chapter 4. HTML5 Hypermedia
The only usefulness of a map or a language depends on the similarity of structure between the empirical world and the map-languages.
- Alfred Korzybski
This last hands-on design chapter covers the techniques involved when using HTML5 as the base media type for your design. Since HTML already has a rich set of hypermedia controls (A, LINK, FORM, INPUT, etc.), the process of designing hypermedia types with HTML focuses on expressing the domain semantics within the existing elements and attributes of HTML.
The scenario here involves expressing common microblogging semantics (Twitter, Identi.ca, etc.) in a hypermedia type. After capturing the semantics and completing the design, a simple server will be built that emits the hypermedia responses along with two distinct client implementations. One client relies on only the HTML responses (no JavaScript support), and the other takes advantage of the Ajax style to build a web bot that knows enough about the hypermedia type to register as a new user (if needed) and begin posting into the data stream.
Scenario
For this example, a functional microblog hypermedia type is needed. This design should allow users to:
Create, update, and delete accounts
Add new messages and share existing messages
Create and remove relationships to other users
Search for existing users and messages
Since the design will be based on HTML5 (an existing hypermedia type), the implementation should provide basic functionality without the need for client-side ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Read now
Unlock full access