XSLT 2.0 and XPath 2.0 Programmer's Reference, 4th Edition (209 page)

BOOK: XSLT 2.0 and XPath 2.0 Programmer's Reference, 4th Edition
13.02Mb size Format: txt, pdf, ePub
ads

or
ordinal=“-er”
in
German
. For other languages with more complicated rules, it's left to the implementor to sort out what to do. For formatting tokens that aren't included in the table above, the XSLT specification is not prescriptive. It indicates that any formatting token may be used to indicate a sequence starting with this token, provided the implementation supports such a sequence; if the implementation does not support such a sequence, it may format the number using the formatting token
1
. So, for example, if an implementation supports the
numbering sequence
α, β, γ, δ
, you can invoke this sequence with a formatting token of
α
.

In case the formatting token does not identify a numbering sequence unambiguously, two attributes are provided to give greater control:

  • The
    lang
    attribute is intended to indicate the target language: for example, the sequence starting with a Cyrillic capital letter
    A
    (x0410 in Unicode) might be different for Russian
    (
    lang=“ru”
    )
    and for Bulgarian
    (
    lang=“bg”
    )
    . The language code is intended to take the same form as the
    xml:lang
    attribute defined in the XML specification.
  • The most obvious case where this changes the output is for the formatting tokens such as
    w
    . For example, if
    lang=“de”
    , the output for
    w
    would become
    eins
    ,
    zwei
    ,
    drei
    .
BOOK: XSLT 2.0 and XPath 2.0 Programmer's Reference, 4th Edition
13.02Mb size Format: txt, pdf, ePub
ads

Other books

In the Arms of an Earl by Small, Anna
Solar Express by L. E. Modesitt, Jr.
Undying Hunger by Jessica Lee
What Pretty Girls Are Made Of by Lindsay Jill Roth
The Duke Diaries by Sophia Nash
Better Together by Sheila O'Flanagan
The Whirling Girl by Barbara Lambert
Stranglehold by Ed Gorman
The Memory by Barbara Kaylor
Blackened by Richards, A.E.