Custom Web Publishing with XML and XSLT

Table Of Contents
Chapter 4
|
Accessing XML data with the Web Publishing Engine 31
Using the fmsresultset grammar
The XML element names in this grammar use FileMaker terminology, and the storage of fields is separated from
the type of fields. The grammar also includes the ability to identify summary, calculation, and global fields.
To use the fmresultset grammar, specify the following name of the fmresultset grammar in the URL
requesting the XML document from the Web Publishing Engine:
fmresultset.xml
For example:
http://192.168.123.101/fmi/xml/fmresultset.xml?–db=employees&–lay=family&–findall
Note When specifying the fmresultset grammar, be sure to use lowercase.
The Web Publishing Engine will generate an XML document using the fmresultset grammar. In the XML
document, the Web Publishing Engine will reference the document type definition for the fmresultset grammar
in the <!DOCTYPE> instruction in the second line of the document, immediately after the <?xml...?> instruction.
The <!DOCTYPE> instruction specifies the URL for downloading the DTD for the fmresultset grammar.
Description of elements in the fmresultset grammar
The fmresultset grammar consists primarily of the <datasource> element, the <metadata> element, and the
<resultset> element.
<datasource> element
In the fmresultset grammar, the <datasource> element contains the table, layout, date-format, time-format,
timestamp-format, total-count, and database attributes.
1 The date-format attribute of the <datasource> element specifies the format of dates in the XML
document:
MM/dd/yyyy
where:
1 MM is the 2-digit value for the month (01 through 12, where 01 is January and 12 is December)
1 dd is the 2-digit value for the day of the month (00 through 31)
1 yyyy is the 4-digit value for the year
1 The time-format attribute of the <datasource> element specifies the format of times in the XML
document:
HH:mm:ss
where:
1 HH is the 2-digit value for hours (00 through 23, for the 24-hour format)
1 mm is the 2-digit value for minutes (00 through 59)
1 ss is the 2-digit value for seconds (00 through 59)
1 The timestamp-format attribute of the <datasource> element combines the formats of date-format and
time-format into one timestamp:
MM/dd/yyyy HH:mm:ss