Re: [xsl] most efficient way to get XML source's parent dir path

Subject: Re: [xsl] most efficient way to get XML source's parent dir path
From: Robert Koberg <rob@xxxxxxxxxx>
Date: Wed, 11 Feb 2009 09:40:48 -0500
On Feb 11, 2009, at 4:51 AM, Owen Rees wrote:

--On Tuesday, February 10, 2009 11:53:24 -0500 Robert Koberg wrote:

I want to get the path to the parent directory of the XML used as the
source in a transformation.

Even if an absolute URI is known for the document supplied as the source, the concept of 'parent directory' is not necessarily well defined with respect to that URI.


What are you expecting to be able to do with the string you are generating?

I want to resolve references to other documents the are relative to the source XML. E.g.


<div>
  <p>blah</p>
  <include ref="blah.xml"/>
</div>
...
match="include"
<xsl:apply-templates select="doc(concat($parent-dir, '/', @ref))/*"/>

What do you see as the problem?

-Rob

Current Thread