Read XSLT 2.0 and XPath 2.0 Programmer's Reference, 4th Edition Online
Authors: Michael Kay
method=“xml”
indent=“yes”
encoding=“iso-8859-1”
cdata-section-elements=“script”
doctype-system=“booklist.dtd” />
The following example might be used if the output of the stylesheet is a comma-separated-values file using US ASCII characters only:
method=“text”
encoding=“us-ascii” />
See Also
Serialization, Chapter 15
xsl:output-character
The
Changes in 2.0
The element is new in XSLT 2.0.
Format
character = char
string = string />
Position
Attributes
Name | Value | Meaning |
character mandatory | Character | A single XML character; the character that is to be replaced during serialization. |
string mandatory | String | Any string; the string that is to replace the character during serialization. |
Content
None. The
Effect
The
The character to be replaced, and the string that is to replace it, must consist entirely of valid XML characters; otherwise, it would not be possible to represent them in the stylesheet. Any special characters must be escaped in the usual way. For example, if you want the ampersand character to be mapped to the string
&ersand;
, write:
See Also
Serialization, Chapter 15
xsl:param
The
Changes in 2.0
An
as
attribute has been added to define the required type of the parameter.
A
required
attribute has been added to indicate whether the parameter is mandatory or optional.
A
tunnel
attribute has been added to support the new facility of tunnel parameters.
Format
Different subsets of the format are applicable to stylesheet parameters, template parameters, and function parameters.
Format for Stylesheet Parameters
name = qname
select? = expression
as? = sequence-type
required? = “yes” | “no”
Format for Template Parameters
name = qname
select? = expression
as? = sequence-type
required? = “yes” | “no”
tunnel? = “yes” | “no”>
Format for Function Parameters
name = qname
as? = sequence-type
Position
stylesheet parameters
,
template parameters
, and
function parameters
. In the case of template parameters and function parameters,
Attributes
Name | Value | Meaning |
name mandatory | Lexical QName | The name of the parameter |
select optional | XPath Expression | The default value of the parameter if no explicit value is supplied by the caller |
as optional | Sequence Type | The required type of the parameter value |
required optional | yes or no | Indicates whether the parameter is optional or mandatory |
tunnel optional | yes or no | Indicates whether the parameter is a tunnel parameter |