Custom Web Publishing Guide

Table Of Contents
138 FileMaker Server Advanced Custom Web Publishing Guide
CDML tag name: Current Time
Tag is replaced with the current time
CDML syntax: [FMP-CurrentTime: Format], where Format is 'Short' (default), or 'Long'
XSLT-CWP conversion:
1 when inside SGML element attribute value, 'Short': {fmxslt:get_time('short')}
1 or, 'Long': {fmxslt:get_time('long')}
1 otherwise, 'Short': <xsl:value-of select="fmxslt:get_time('short)" />
1 or, 'Long': <xsl:value-of select="fmxslt:get_time('long)" />
CDML tag name: Current Token
Tag is replaced with the value of –Token variable tag used to create the current page
CDML syntax: [FMP-CurrentToken: Number, Encoding], where Number is '0'...'9' (optional), and Encoding is
'Raw', 'URL', or 'HTML' (default)
XSLT-CWP conversion:
1 when inside SGML element attribute value: {$request-query/fmq:query/fmq:parameter[@NAME='–token']}
1 otherwise: <xsl:value-of select="$request-query/fmq:query/fmq:parameter[@NAME='–token']" />
1 if the token has a Number, the query parameter is '–token.Number'; for example, '–token.5'
Conversion example
Original CDML: Current sort order is:<br>
[FMP-CurrentSort]
Field: [FMP-SortFieldItem], Order: [FMP-SortOrderItem]<br>
[/FMP-CurrentSort]
Converted XSLT-CWP: Current sort order is:<br />
<xsl:for-each select="$current-sort/sort-field">
Field: <xsl:value-of select="@name" />, Order: <xsl:value-of select="@order" /><br />
</xsl:for-each>
Converted Result: Current sort order is:<br>
Field: First Name, Order: descend<br>
Field: Last Name, Order: descend<br>
Conversion example
Original CDML: Current time is: [FMP-CurrentTime: Short]
Converted XSLT-CWP: Current time is: <xsl:value-of select="fmxslt:get_time('short')" />
Converted Result: Current time is: 10:12 AM