Re: [xsl] Parsing & Paths

Subject: Re: [xsl] Parsing & Paths
From: Jörg Heinicke <joerg.heinicke@xxxxxx>
Date: Sat, 20 Oct 2001 00:23:54 +0200
Hi Kris,

at first I want to show you a shorter example of your code:

    <xsl:attribute name="id">
        <xsl:value-of select="substring-after(/BoundingBox, '#')" />

to so called 'attribute value template'

<FILTERCOORDSYS id="{substring-after(/BoundingBox, '#')}"/>

Then you must access the value of the attribute srsName of BoundingBox, not
boundingBox itself:

<FILTERCOORDSYS id="{substring-after(/BoundingBox/@srsName,'#')}"/>

<ENVELOPE minx="{/BoundingBox/gml:coord/gml:x}"

With <xsl:value-of select=""> (or the attribute value template used above)
you get the value of the first occurence of the XPATH-expression. So you
must not write minx="{/BoundingBox/gml:coord/gml:x[1]}". The [2] (or [1]) is
the same like [position() = 2] and '[]' is a filter for the selected nodes.
So [2] selects the value of the second occurence of the node.

For more information about XSLT and XPATH look at,, or (links).

Hope this helps,


 XSL-List info and archive:

Current Thread