DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT <http://nagoya.apache.org/bugzilla/show_bug.cgi?id=7894>. ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND INSERTED IN THE BUG DATABASE.
http://nagoya.apache.org/bugzilla/show_bug.cgi?id=7894 document function and uri's beginning with slash Summary: document function and uri's beginning with slash Product: XalanJ2 Version: CurrentCVS Platform: All OS/Version: All Status: NEW Severity: Minor Priority: Other Component: org.apache.xalan.xsltc AssignedTo: [EMAIL PROTECTED] ReportedBy: [EMAIL PROTECTED] If the uri specified in the document() function begins with '/', it is taken to be an absolute uri when it shouldn't. For example, when the base uri is http://someserver/path/file.xsl, the function document ('/otherpath/otherfile.xsl') should look for the uri "http://someserver/otherpath/otherfile.xsl" but instead it looks for "/otherpath/otherfile.xsl" which is taken to be a file on the local system. It looks like the issue is in org.apache.xalan.xsltc.dom.LoadDocument. Instead of checking to see if the uri starts with a slash (other checks seem valid) and then just concating the base and the uri, it should skip the check. Also, simply concating the results will not yield the correct results, so perhaps creating a java.net.URL from the base, and then using this to construct another URL for the result would be the easiest: java.net.URL url1 = new java.net.URL(base); java.net.URL url2 = new java.net.URL(url1, uri); uri = url2.toString()
