Egg Off the Wall

Twitter Updates

HashTags

#PKNsf
San Francisco PechaKucha Night
#IXDAsf
San Francisco IxDA

Blogroll

One of the main reasons I’m bringing this site alive again is because of my new job—editor of an online magazine—and the redesign we’re planning. Currently, just about every article on the site lives in three (or more) duplicate versions that are classic HTML tag soup–the main document (full of nested tables, etc., formatted for desktop browsers, and sometimes split up into pages), the printer-friendly version, and the mobile (AvantGo) version.

I’d like to reduce this old-school architecture as part of the redesign and move to an XHTML-based design that doesn’t need multiple versions, but the well-known limitations of browsers and their content negotiation is the Monkey wrench that is making it difficult to scale that brick wall.

So here’s my strategy for climbing the wall.

Since many of the mobile phone vendors will be there, I’d like to use the opportunity to briefly evangelize them, and perhaps even convince them to make the slight changes to their browsers that would enable seamless, basic content negotiation between a few reasonable formats.

Here’s what I’m thinking of:

  • an XHTML 1.0 Transitional page that is the desktop browser page
  • an XHTML Basic page that is designed for PDAs and AvantGo-like browsers (derived directly from the above page)
  • an XHTML Mobile Profile page for mobile phones (for when there is appropriately sized content)

But how exactly should these be identified via MIME types and quality parameters so that browsers and servers can distinguish among them? The obvious method is to serve each with a distinct MIME type:

text/html
for XHTML 1.0 Transitional
application/xhtml+xml
for XHTML Basic
application/vnd.wap.xhtml+xml
for XHTML Mobile Profile

This has several problems. One is that serving XHTML as text/html is not ideal, even though it is required to support IE. Two is that application/vnd.wap.xhtml+xml is not actually registered as a MIME type. (Yes, I know thre is that no mobile phone browser actually sends the Q factor that would enable content negotiation, but that’s what I’m hoping to evangelize the mobile vendors about.)

Of course, it is perfectly valid to serve all of these documents as application/xhtml+xml, but then how does one differentiate them for content negotiation? Is the following an appropriate solution?

application/xhtml+xml;level=1.0
for XHTML 1.0
application/xhtml+xml;
profile="http://www.w3.org/TR/xhtml-basic/xhtml-basic10.dtd"
for XHTML Basic
application/xhtml+xml;
profile="http://www.wapforum.org/DTD/xhtml-mobile10.dtd"
for XHTML Mobile Profile

Or how about this?

application/xhtml+xml;level=1.0
for XHTML 1.0
application/xhtml+xml;level=Basic1.0
for XHTML Basic
application/xhtml+xml;level=Mobile1.0
for XHTML Mobile Profile

Whatever solution is decided upon, it had better be flexible enough to let us differentiate among future doctypes, such as xhtml + svg + smil + mathml + whatever.

Author: Peter Sheerin

Peter Sheerin is best known for the decade he spent as the Technical Editor of CADENCE magazine, where he was the acknowledged expert in Computer-Aided Design hardware and software. He has a long-standing passion for improving usability of software, hardware, and everyday objects that is always interwoven in his articles. Peter is available for freelance technical writing and product reviews, and is exploring career opportunities in interaction design. His pet personal project is exploring the best ways to harmonize visual, tactile, and audible symbols for improving the effectiveness of alerting systems.

Leave a Reply