Coding With Fun
Home Docker Django Node.js Articles Python pip guide FAQ Policy

XSLT document() function


May 28, 2021 XSL T


Table of contents


XSLT document() function

The XSLT document() function has access to external XML documents that can be resolved correctly.


XSLT document() function The complete XSLT function reference object

Definitions and usages

The document() function is used to access nodes in external XML documents. External XML documents must be legal and resolvable.

One way to use this function is to find data in an external document. For example, we wanted to find a value of Celsius that corresponds to a degree Fahrenheit value, and we visited a document that contains the estimated value:

<xsl:value-of select="document('celsius.xml')/celsius/result[@value=$value]"/>


Grammar

node-set document(object,node-set?)

Parameters

parameter describe
object Required.Define the URI of the external XML document.
node-set Optional.Used to parse the relative URI.


XSLT document() function The complete XSLT function reference object

Related tutorials

XML tutorial