Chapter 7: Extensible Stylesheet Language (XSL) and FileMaker Pro

Chapter 7: Extensible Stylesheet Language (XSL) and FileMaker Pro


An XML document can contain the data and metadata of fields and field contents from many sources. FileMaker Pro produces well-formed XML, which can be transformed into Hypertext Markup Language (HTML), Wireless Markup Language (WML), text, or other formats specific to various devices, including another XML document. Transformation for different devices from the same XML source document can be accomplished with the use of stylesheets.

The XML transformation process occurs by different methods. The most common method uses an Extensible Stylesheet Language (XSL) document embedded with commands to read the XML document tree and produce XML, HTML, WML, or other formats. Browsers that can read both XML and XSL documents will perform the transformation as a client-side process. In the second method, servers can be used to process the XML with stylesheets and transform XML into other formats. The results are sent to the client as transformed text, most commonly in HTML format. The third method to transform XML uses applications to convert the data into formats usable by other devices. This chapter discusses the transformation of the XML produced by FileMaker Pro with the use of XSL stylesheets. The stylesheets may be used with FileMaker Pro 6 export or import, or with web-published XML from FileMaker Pro.

The document "Extensible Stylesheet Language (XSL) Version 1.0,", states that XSL is a language used for transforming XML as well as formatting the output. Formatting may be applied to different devices in unique ways. XSL encompasses the XSLT (Transformation) markup and the Formatting Objects markup (FO) along with the XPath and XPointer expressions for resolving the location of the elements and attributes to be transformed or formatted. It is beyond the scope of this chapter to cover all of the formatting capabilities of XSL.

The XSL commands listed here will be a general set in the XSLT 1.0 standard, which may also be usable by common web browsers to transform XML into HTML. The Xalan processor built into FileMaker Pro for use with import and export supports XSLT 1.0 and XPath 1.0. The document "XSL Transformations (XSLT) Version 1.0" found at contains the XSLT 1.0 standards, and the document "XML Path Language (XPath) Version 1.0" found at contains the XPath 1.0 standards. This chapter will further explain the XPath functions as they are used with XSLT and FileMaker Pro 6.