The author

XForms: the only Standard Web Framework

Steven Pemberton, CWI/W3C, Amsterdam


The Web has turned into a programming environment, turning its back on its earlier roots of simplicity and ease-of-use. And in the process many properties of the early web have been lost. This talk will examine some of the desirable properties of a future web, such as accessibility, usability, semantics, decentralisation, privacy, aggregation and even what to do about the password problem.



The big advantage of standards is that you don't get locked in. If you don't like what a browser (or photo-viewer, or whatever) does, well, just download a different one and use that instead.

On the other hand, using a proprietary format restricts which software you can use, and if you want to change, you have to convert all your documents.


The key term for describing the original web (and I would claim, its success) is the word "declarative".

A declarative definition is where you describe what you want, rather than how to get it.

Declarative definitions are typically short, and easy to understand.

Declarative Markup

The poster-child of HTML declarative markup is the hyperlink:

<a href="talk.html" title="My talk" target="_blank" class="overt">HTML5 is the new Flash</a>

This compactly encapsulates a lot of behaviour including: what the link looks like, what happens when you hover over it, activation in several different ways, what to do with the result, hooks for presentation changes.

Doing this with programming would be a lot of work.


Unfortunately, we now have HTML5. HTML5 is no longer about declarative markup: it is about programming.

The designers of HTML5, themselves mostly programmers, rather than researching what people needed from the web, and then defining declarative ways of describing those things, took the position that if you want something new, you should just program it.

So even something as simple and obvious as a drop-down navigation list needs to be programmed out.

This is no longer easy. And furthermore, it is no longer standard.


Why isn't it standard?

Most web-authors are not programmers, so to help them, along came Frameworks. Lots of them. Wikipedia lists 30, but there are certainly many more.

But they are all different! They are not standardised.

If your framework of choice no longer gets supported, or doesn't work on one of the browsers you want to support, what are you going to do? Because you will have to recode all your documents if you want to change. How about in 5 or 10 years? How many of those frameworks will be still working and supported? (At least one has already died.)


There is only one standardised Framework: XForms.

It is a W3C standard, in use worldwide:


There are many implementations, such as:

*=open source

An Example

I am going to work through an extensive example.

It is coherent (it really does something)

It uses most parts of XForms

It is amazingly fun!

But first a (very quick) introduction to the principles.

The Essence of XForms

Strict separation between data and controls

Live data+constraints

Abstract controls

Everything is data

State+state change+(inter)action

The Essence: Intent-based Controls

Controls, rather than expressing how they should look (radio buttons, menu, etc), express their intent ("this control selects one value from a list").

You then use styling to say how they should be represented, possibly with different styling for different devices (as a menu on a small screen, as radio buttons on a large screen).

These three controls are all identical (and bound to the same data), except they are presented differently. (All examples in these slides are live)


Everything is (live) data

Try changing the first field:


And now...

The example.