[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message]

Re: Please Confirm that xsl:document instruction canno

Subject: Re: Please Confirm that xsl:document instruction cannot have a document URI
From: Michael Kay <mike@xxxxxxxxxxxx>
Date: Wed, 28 Aug 2013 18:01:54 +0100
Re:  Please Confirm that xsl:document instruction canno
There's a difference between document-uri and base-uri. document-uri is a URI
that can be used to fetch the document using the doc() function. base-uri is a
URI that can be used to resolve relative URIs contained in the document. You
talk about document-uri, but I think you mean base-uri.

As David points out, you can control the base URI of the constructed document
using an xml:base attribute in the stylesheet.

You can't set a document URI (it's a temporary tree with no means of external
identification. That means that the garbage collector knows when it can kill
it. This wouldn't be the case if it had a document URI. If you want to create
a document with a document URI, use xsl:result-document - except you can't
then access it during the same transformation.)

Michael Kay
Saxonica


On 28 Aug 2013, at 17:17, Eliot Kimber wrote:

> I tried to find an answer to this question but neither Google nor MarkMail
> revealed a definitive answer.
>
> I have code that constructs a document using <xsl:document> and then passes
> it to a 3rd-party function library that expects the input document to have
a
> URI so that it can then resolve relative URI references.
>
> Based on my reading of the XSLT 2 spec and what I could find in my
searches,
> it appears that there is no standard way to define a document URI for
> documents created using <xsl:document>.
>
> This seems like a bit of an oversight in the spec, so I wanted to get
> confirmation that my analysis is correct, that I cannot use <xsl:document>
> alone as input to functions that expect to get a non-null document-uri()
> value.
>
> Thanks,
>
> Eliot
> --
> Eliot Kimber
> Senior Solutions Architect, RSI Content Solutions
> "Bringing Strategy, Content, and Technology Together"
> Main: 512.554.9368
> www.rsicms.com
> www.rsuitecms.com
> Book: DITA For Practitioners, from XML Press,
> http://xmlpress.net/publications/dita/practitioners-1/

Current Thread

PURCHASE STYLUS STUDIO ONLINE TODAY!

Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced!

Buy Stylus Studio Now

Download The World's Best XML IDE!

Accelerate XML development with our award-winning XML IDE - Download a free trial today!

Don't miss another message! Subscribe to this list today.
Email
First Name
Last Name
Company
Subscribe in XML format
RSS 2.0
Atom 0.3
Site Map | Privacy Policy | Terms of Use | Trademarks
Free Stylus Studio XML Training:
W3C Member
Stylus Studio® and DataDirect XQuery ™are products from DataDirect Technologies, is a registered trademark of Progress Software Corporation, in the U.S. and other countries. © 2004-2013 All Rights Reserved.