Calling XSLT transformation
Simple Transformation
xquery version "3.0";
let $input := doc("/db/apps/demo/examples/basic/Items.xml")
let $xsl := doc("/db/apps/demo/examples/basic/ConvertItems.xsl")
return
transform:transform($input, $xsl, ())
View source: Items.xml, ConvertItems.xsl
Transform Shakespeare's Hamlet to HTML
xquery version "3.0";
let $input := doc("/db/apps/demo/data/hamlet.xml")
let $xsl := doc("/db/apps/demo/data/shakes.xsl")
return
transform:transform($input, $xsl, ())
View source: shakes.xsl, hamlet.xml