You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@forrest.apache.org by Peter Meggitt <pm...@eviasoft.com> on 2004/02/23 19:31:09 UTC

XPath expressions

I am to create an XML transformation that allows XML attributes and elements
to include (with some suitable delimiter) XPath expressions. For example
below, the expression {../@id} would get replaced by the evaluation of the
XPath expression ../@id. So:

<tournament id="Big">
  <desc>A big tournament</desc>
  <tournament id="{../@id}.day1"/>
  <tournament id="{../@id}.day2"/>
</tournament>

would get transformed to:

<tournament id="Big">
  <desc>A big tournament</desc>
  <tournament id="Big.day1"/>
  <tournament id="Big.day2"/>
</tournament>

Does anyone know of an XSLT transformation or other XML spec that would
allow the evaluation of (XPath) expressions during the transformation
process?



Re: XPath expressions

Posted by Clay Leeds <cl...@medata.com>.
This is probably better suited for the XSLT mailing list (or possibly 
an XPath list, but a post to XSLT may get results):

http://www.mulberrytech.com/xsl/xsl-list/

Good luck!

Web Maestro Clay

On Feb 23, 2004, at 10:31 AM, Peter Meggitt wrote:

> I am to create an XML transformation that allows XML attributes and 
> elements
> to include (with some suitable delimiter) XPath expressions. For 
> example
> below, the expression {../@id} would get replaced by the evaluation of 
> the
> XPath expression ../@id. So:
>
> <tournament id="Big">
>   <desc>A big tournament</desc>
>   <tournament id="{../@id}.day1"/>
>   <tournament id="{../@id}.day2"/>
> </tournament>
>
> would get transformed to:
>
> <tournament id="Big">
>   <desc>A big tournament</desc>
>   <tournament id="Big.day1"/>
>   <tournament id="Big.day2"/>
> </tournament>
>
> Does anyone know of an XSLT transformation or other XML spec that would
> allow the evaluation of (XPath) expressions during the transformation
> process?
>
>