Subject: Re: [xsl] anyURI problem From: Andrew Welch <andrew.j.welch@xxxxxxxxx> Date: Fri, 26 Aug 2011 09:42:04 +0100 |
On 26 August 2011 09:33, Jan Pour <xpouj04@xxxxxxxxx> wrote: > Hi, > > I tried both ways of how to cope with [Content_Types].xml > file in xsl:result-document href attribute: > >> Try using the iri-to-uri() function to turn this into a valid URI. >> >> Saxon is fussier than some other products about insisting that URIs are >> valid. >> >> Michael Kay >> Saxonica > >> That didnt work for me, but >> href="{encode-for-uri('[Content_Types].xml')}" >> did. >> >> Or verbose >> href="%5bContent_Types%5d.xml" >> >> Gerrit > > in Saxon 8 I was able to generate such file, but with versions 9.* > I was not successful. With encode-for-uri() function 0-length file was > generated with following error message: > > java.net.URISyntaxException: Illegal character in path at index 21: > file:///C:/xslt/test/[Content_Types].xml > > I tried Saxon versions: 9, 9.1 and 9.3he > Is there any other solution? If you don't post the code it's hard to see where you are going wrong.... Guessing, you've probably wrapped the whole path in encode-for-uri, rather than just the filename: href="{concat('file:///C:/xslt/test/', encode-for-uri('[Content_Types.xml'))}" -- Andrew Welch http://andrewjwelch.com
Current Thread |
---|
|
<- Previous | Index | Next -> |
---|---|---|
Re: [xsl] anyURI problem, Jan Pour | Thread | Re: [xsl] anyURI problem, Imsieke, Gerrit, le- |
Re: [xsl] anyURI problem, Jan Pour | Date | Re: [xsl] anyURI problem, Imsieke, Gerrit, le- |
Month |