Menu

Semantic Information Threatened by XSL

May 20, 1999

Michael Leventhal

I can understand why overworked undergraduates think FONT is cool, but I'm very disappointed when a group of highly skilled adults tell kids to stop playing, form a committee - and then come out with a set of supercharged FONT tags.

Håkon Lie on XSL Formatting Objects, xsl-list, 28 April 1999

Dear Mr. Lie (co-inventor of CSS) has penetrated once again to the essence of a matter ... and in his inimitable style. If I could only win friends and influence people like that! I highly recommended that you go and get the full story from his paper "Formatting Objects considered harmful" at http://www.operasoftware.com/people/howcome/1999/foch.html. A short version of the story is this: XSL proposes the existence of something called a formatting object, XML elements which indeed resemble what Mr. Lie calls a supercharged FONT tag. It is the final result of an XSL transformation which is sent to the rendering engine. If the rendering engine reads formatting objects directly, all the semantic information in the original information may be lost. This is exactly the information we get through element events and the DOM to make all of our 'Zilla applications work. XSL, in this scenario, would destroy XML on the Web.

Among the solutions to this problem is stipulating in the standard that formatting objects must preserve a mapping back to the original XML element. Technically not very elegant and probably unenforcable.

Another solution is to legislate that formatting objects not be allowed to ever physically exist as XML. Not bloody likely, but there is a logical candidate to replace XML formatting objects: CSS! One must ask why don't we just forget about formatting objects and just use CSS in the first place?