Steven Pemberton was already sold on usability back in the 1980's, when he was building user interface technology, and he continues to identify "people" (aka usability) as the thread running through all the projects he's involved in. The opportunity to influence W3C in this direction came in 1995, when Steven became the first chair of the HTML Working Group. Today, Steven continues to see usability as the clear convergence point for the interests of technology, business, and the general public, and is a passionate champion of the standards that he believes will cause this convergence to occur. He is also an extremely articulate writer, with a rare talent for relating technology to the real life experience of millions of non-technical Web users. In 2007, Steven continues to chair the HTML Working Group at W3C.
- Vlad Alexander
- Why do we need XHTML 2? When did this need become apparent?
- Steven Pemberton
HTML is an incredible success story, it is the most successful document format ever. But it has become a sort of Garden of Eden into the bargain, with all sorts of "Thou Shalt Not" guidelines telling you how to use it properly, such as for accessibility, usability, internationalization, metadata, device-independence and on and on. In fact to write 'proper' HTML you have to hold a vast amount of information in your head.
On top of this, all of these communities (and more) have come to us with new requirements for HTML. In a perfect world, HTML would be accessible out of the box, so that blind and partially-sighted people (which we will all be one day) can use the web as easily as the sighted. As another example, you don't want to have to write your site once for every sort of device that comes a long - if HTML were device-independent it would work equally well on all devices. So XHTML 2 is about collecting requirements from as many communities as possible, and creating a consistent, coherent design that addresses as many of those requirements as possible.
But good design is not just throwing a bunch of features together. For instance, we have been asked to add a huge number of new elements to XHTML 2, and if we had just added them the language would be an unmanageable mess. To quote an extreme example, we were asked to add an element to represent irony. We eventually ended up with a design that allows you to layer semantics —meaning— onto XHTML, in the same way that CSS allows you to layer presentation. So XHTML retains a small number of elements for structuring documents, and anyone can add any meaning on top, whether it's irony, anger, sarcasm, or whether they want to say the text represents a person, an event, a book reference, a chemical compound or whatever.
- Vlad
- XHTML 2 is sometimes referred to as a "host" language. Can you define what a host language is? What kind of things will be "hosted" by XHTML 2?
- Steven
The W3C XML architecture allows you to mix different markup languages in a single document. For instance you might have a document with XHTML, a bit of Math in the form of MathML, and some graphics using SVG. We needed terminology to distinguish markup languages that could 'host' such a document (that is supply the root element and structure), and languages that are only designed to be a part of another document. XHTML and SVG are examples of languages that can host or be hosted, but XForms for instance is only designed to be hosted.
The advantages of this design is its modularity. As a consequence you don't have to keep stuffing HTML full of new features for graphics, multimedia, mathematics and so on: you just let HTML do what it is good for, handling hypertext, and you let other expert groups design the markup that they understand for the other areas, which you can then combine in a single document.
Microsoft Internet Explorer, as an example, has almost a perfect implementation of this. It allows you to specify which add-on bit of code is responsible for which bit of markup (as identified by namespaces), and it just works. You grab an SVG implementation, and an XForms implementation and a MathML implementation, and they all just work together in a single document.
I say almost perfect: the only problem is that the document itself has to say which program does what, rather than the user deciding. It should really be up to the end user to decide which SVG implementation should be used: the document should remain neutral.
- Vlad
- XHTML 2 introduces new markup constructs such as navigation lists, a new headings structure, better paragraphs, new ways to reference images, a new way to create hyperlinks, and much more. Can you briefly describe these new constructs and the reason they were added?
- Steven
Many of these are for better document structure, but they help accessibility and device-independence into the bargain. When we started on XHTML 2 we did an analysis of thousands of HTML pages to see how people used HTML. A German student analyzed tens of thousands of pages for us to see which tags were being used, which attributes, which class names and so on. What we wanted to do was see what people were trying to do with HTML, and see if there were use cases we should support. One case that stuck out was the navigation list. You see them in lots of different forms: as navigation bars across the top of a page, or down the side, or as a menu of navigation points, well, go to any major site and you'll see dozens of them. By explicitly marking them up as navigation lists, you are not only structuring your page better, you are also automatically making your page more accessible. When a sighted person goes to a page, they can immediately hone in on the content of the page. But a non-sighted person, who has the page read to them by the browser, has to listen to all the navigation links before finally getting to the meat of the page. Now that the page says —in a standard way— what is navigation and what isn't, the browser can skip straight to the content, leaving the navigation parts as an option for the user. Similarly for device-independence: on a small screen device you might choose to display navigation lists as menus, while on a big screen as navigation bars.
The new headings structure is similar. In existing HTML the structure of a page is often only suggested by the level of headings that have been used. So a blind person coming across an h2 element assumes that a new section is starting. But if that section is followed by an h4 (rather than an h3) the person doesn't know what to make of it. XHTML 2 allows you to explicitly mark up the sections of the document; this isn't only good for accessibility: it allows you to make browsers that fold and unfold sections (great for getting an overview, and great for small screens), and it is great for PHP use, since now you can import a section without having to worry where it will be imported, and therefore what level of heading it should have.
I could go on, but I hope you get the idea.
- Vlad
- Why does XHTML 2 keep legacy markup constructs such as numbered headings, the
img element, and the a element? - Steven
- There's a big tension between those people who would like to see XHTML 2 as a pure language with only the use of the new facilities, and those who want to be able to continue to use the old markup, and keep the new language 'backward compatible'. In a situation like that, where you are trying to reach consensus, your only option is to keep the old stuff: then people who want to use the old stuff can, and people who want to be pure can ignore the old stuff.
- Vlad
- In HTML 4 and XHTML 1, form controls such as text fields, list boxes and radio buttons allow Web developers to build interactive Web applications. XHTML 2 will support a new forms mechanism called XForms. What will Web developers be able to do with XForms that they cannot do now?
- Steven
XForms can do everything that HTML Forms can do, but it also allows you to say that fields are required, or of a certain type, or have certain constraints (such as the departure date must be before the return date), or that some values are calculated from others (such as the amount to pay is the sum of all the line items).
It also allows you to preload data into a form from the internet, such as initial values, and submit them and replace them with the results, which means you can do lots of Ajax-style applications without needing to use script. When you've got input and output elements, and a calculation engine, you can do lots of things that look like an application.
XForms is, of course, designed to be accessible and device-independent out of the box. This means for instance that the markup doesn't commit you to the particular controls needed for a value: you might use radio buttons on a big screen, and menus on a small screen device.
It seems like the XForms community discovers new uses of XForms every day, but the most amazing use of XForms that I have yet seen is a version of Google maps, except in about 10 times less code.

- Vlad
- The most exciting feature in XHTML 2 has to be the
role attribute. Can you describe how this feature will favor Web accessibility and make it easier to get more relevant results when searching on the Web? - Steven
- It seems like different things in XHTML 2 excite different communities, but the
role attribute has been quickly seized on by several different groups. It is part of the facilities that I described earlier to add semantics to elements. The role attribute allows you to say what the element is supposed to be doing (ever seen a Web page that seems to be just thousands of nested divs?). This allows software to do useful things with the content, whether it be a search engine, a browser, or a server. For accessibility you might be able to identify which part of the page is about news, and bind a shortcut key to take you straight there; a server might transform a page automatically so it is more suitable for a small device. - Vlad
If an XHTML 2 Web page contains errors in the markup, such as a missing closing tag or incorrectly nested elements, most Web browsers will display an XML parsing error message such as the one seen below.

Since we've become so accustomed to Web browsers making adjustments for invalid markup, and consequently succeeding in rendering almost anything, including "tag soup", won't many Web users find the browser's refusal to render XHTML 2 Web pages with markup errors rather harsh? Has this aspect been discussed at W3C? If so, what are some possible solutions under consideration to improve the user experience?
- Steven
There are so many possible answers to this question. First I should say that this isn't a requirement of XHTML 2, but a requirement of XML. And since XHTML 2 is in XML, it inherits the rule. But look at it this way: if all browsers refused to display incorrect pages, the only person who would ever see such an error message for a page would be its author, who would quickly correct the page before it went out. This would be an improvement over the current position. Why? Well, if a page is incorrect, the browser has to correct it silently. But different browsers correct pages in different ways, so a page that has been corrected by the browser is likely to look different in different browsers. I could show you dozens of screen dumps of pages that only work in some browsers because the markup is wrong. So I would say that the new rule has the chance of improving the user experience. But only if all browsers agree to implement the rule.
But look at it another way: suppose that all compilers silently corrected errors in your programs... it's not as bad on the Web, but it's comparable.
- Vlad
- Advertiser programs like Google's AdSense currently do not work when Web pages are served as XML. These ad programs are very popular and displaying these ads on their sites is an important source of income for small content providers. What is being done to make sure these ad programs will work with XHTML 2?
- Steven
- I'm assured by people in the know that this change is coming.
- Vlad
- XHTML 2 is currently in Working Draft stage. What is the tentative timetable for moving XHTML 2 through the standards approval process towards Recommendation stage?
- Steven
- We're working hard to get XHTML 2 to last call, but we have to have answered all comments we've had to date before we can, and we've had thousands of comments! We should get to last call this year. After that it is a question of implementations, but I know of three already, so I am optimistic on that front.
- Vlad
- How important is community feedback? At what stage of the standards approval process can individuals (non-W3C members) give feedback to the people who are writing the XHTML 2 specification?
- Steven
- Incredibly important! Anyone can give feedback at any stage, and all the documents say that as well. In fact dealing with comments is the part that takes the most time. We have had ten thousand comments already, and we are required to track and reply to all of them.