Changes

Jump to navigation Jump to search
926 bytes added ,  11:52, 3 June 2023
on using xmlresolver.org for XSLT includes/imports
The same URI rewriting works for resources retrieved by the <code>doc()</code> function from within an XSLT stylesheet. See [[XSLT Module]] for details on how to invoke XSLT stylesheets from within BaseX.
NOTE: This URI rewriting is currently restricted to XSLT stylesheets. It has neither been enabled yet for the XQuery function <code>doc()</code> nor for XSD schema locations. It needs Norman W⁠alsh’s resolver mentioned above, the Java resolver apparently does not work for XSLT includes/imports in stylesheets run by Saxon using <code>xslt:transform()</code> et al. See the note below about setting the <code>org.basex.catalog</code> property for Norm’s xmlresolver.org resolver.
===GUI Mode===
The catalog location in the pragma can be given relative to the current working directory (the directory that is returned by <code>file:current-dir()</code>) or as an absolute operating system path. The catalog location in the pragma is not an XQuery expression; no concatenation or other operations may occur in the pragma, and the location string must not be surrounded by quotes.
 
As mentioned above, the Java resolver doesn’t work for XSLT include or import URIs when executing XSLT with Saxon. You can use Norman Walsh’s xmlresolver.org instead. The catalog location may be given as a path relative to the current working directory as described above. When you want to specify it as an absolute path, this resolver expects a file URI, not a file system path. Example for setting it on Windows prior to executing one of the .bat scripts, such as bin\basexgui.bat:
 
<syntaxhighlight lang="bat">
set BASEX_JVM="-Dorg.basex.catalog=file:///c:/Users/Jane/path/to/catalog.xml"
</syntaxhighlight>
=Changelog=
editor, reviewer
9

edits

Navigation menu