xsl-list
[Top] [All Lists]

Re: \

2003-12-04 07:27:12

'\'  by itself is not prohibited in URLs, is it?
no, but it doesn't mean what people think it means (it has the same
status as "a")


Is "http://example.com/\data\file.xsl"; an invalid URL? 

No, but it  has a _single_ path component called "\data\file.xsl" so if
that file has an <xsl:include href="foo.xsl"/> then foo.xsl is a
relative uri that corresponds to
"http://example.com/foo.xsl";
which probably is not what was intended.

If the same file is served from
"http://example.com/data/file.xsl"; 
then the relative foo.xsl uri will resolve to
"http://example.com/data/foo.xsl"; 


Note that even if the server tries to be kind and silently map \ to /
(as it may do as it is free to map uris to its file system in any way it
likes) then it will still fail as a _client_ given that relative URI is
mandated to ask for http://example.com/data/foo.xsl as it is the client
that resolves the relative uris and requests an absolute uri from the
server.


Putting it another way, I think it is legal to write

<xsl:import href="module1\stylesheet1.xsl"/> 

its legal but the base uri of the included file might not be what you
expect.

David




-- 
http://www.dcarlisle.demon.co.uk/matthew

________________________________________________________________________
This e-mail has been scanned for all viruses by Star Internet. The
service is powered by MessageLabs. For more information on a proactive
anti-virus service working around the clock, around the globe, visit:
http://www.star.net.uk
________________________________________________________________________

 XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list



<Prev in Thread] Current Thread [Next in Thread>