XSLT document() function with escaped chars in file name -
am parsing xml file names escaped characters. file name on server:
account-v%29%27%22%3b%3a%3e.layout
when apply document function, automatically transforming escaped characters.
`<xsl:apply-templates select="document('account-v%29%27%22%3b%3a%3e.layout')/layout"/>
the above yields error cannot find file on server:
account-v)'";:>.layout
is there way tell document() function not transform escaped chars in file? tried wrapping around variables did not work.
if you're using xslt 2.0, try using encode-for-uri()
select="document(encode-for-uri('account-v%29%27%22%3b%3a%3e.layout'))/layout"
Comments
Post a Comment