Make the most of XSL-FO; lively up those Web services!
- By Jack Vaughan
[PROGRAMMERS REPORT, OCTOBER 22, 2002] -- XML has been asked to do a lot since its startling inception in the late
'90s. The same is true for a host of XML-related standards. Although
conceptually simple, implementation of these standards, especially when coupled
with complex Java and .NET environments, can be challenging in the hands of
newcomers. And few in XML are not in the category of newcomer.
One highly versed ''XML-ist'' is G. Ken Holman of Crane
Softwrights Ltd. He has served many years in high-tech, taking part in efforts
to create videotext systems (those forgotten predecessors to the Web) and SGML
document systems. He is the author of Definitive XSLT and XPath
(Prentice Hall PTR, 2001), and
former chair of the OASIS XML Conformance Technical Subcommittee. These days,
Holman's efforts center on training people in the use of XSLT, which allows
systems to transform documents conforming to the Extensible Stylesheet Language
standard for expressing stylesheets.
Among matters that concern Holman, as he watches XML spread and evolve, is
the treatment of documents. In XML-based Web services especially, he noted in a
recent conversation with Programmers Report, the rush to create
machine-to-machine communications systems often ignores the still-important role
printed documents play in business-to-business (B2B) efforts.
B2B efforts aside, the notion of Web services for consumers implies that many
people, including many grandmas and grandpas used to holding documents, must be
comfortable with the process. Holman wonders if Web services creators are aware
of a companion recommendation to XSLT known as XSL-FO (for Extensible Stylesheet
Language Formatting Objects), which provides a framework for the useful
formatting of semantics for paginating information for better browser navigation
and print support.
''No one accepts print from a Web browser as a quality paginated result. No
one likes printing their browser screen,'' said Holman. ''The ubiquitous final
form for print from the Web today is PDF.'' A solution here is XSL-FO, which
Holman describes as ''an XML vocabulary for paginating structured
''I think Web service implementers are ignoring whole constituencies of print
users who refuse to read the screen and who want to use paper,'' added
He noted that using XSL-FO allows developers to produce results to make the
''paper Web experience decidedly better.''
A lot of people are learning XSLT these days. What they think about it may vary according to what they do with it. One misunderstanding may be that it is ‘a language,’ as in ‘a programming language.’
“Some people claim XSLT is a bad programming language, and I agree,” said Holman. “It should not be regarded as a programming language. It should be described as a templating language.” Understood as such, it may be made more accessible to nonprogrammers, Holman indicated.
To work effectively with XSLT, users should realize that it was designed more for template implementers, than for template writers, Holman indicated. “The goal of XSLT is to supply the [XSLT] processor with enough examples so it can assemble the result from them,” he said.
When people try to use XSLT as a programming language, missteps may follow.
What is XSL-FO? Ken Holman on XML.com
To Cranesoftwrights’s site
To Cranesoftwrights’ Resource Library, offering books in full and in excerpt
For other Programmer Report articles, please go to http://www.adtmag.com/article.asp?id=6265
Jack Vaughan is former Editor-at-Large at Application Development Trends magazine.