xsl-list
[Top] [All Lists]

Re: [xsl] problem with intersect in match pattern

2014-06-06 05:44:22
Szabo, Patrick (LNG-VIE) patrick(_dot_)szabo(_at_)lexisnexis(_dot_)at wrote:

I have the following variable

<xsl:variable name="var1">
         <xsl:copy-of select="//desiredelement"/>
</xsl:variable>

I think you want
  <xsl:variable name="var1" select="//desiredelement"/>
to select the original elements and not to create a copy of element as you currently do.

Afterwards I'd like to match any element that matches the xpath 
"//desiredelement" i.e. is in var1.

<xsl:template match="*[. intersect $var1]">
...
</xsl:template>

...which doesn't work at all.

Then the intersection should work.
--~----------------------------------------------------------------
XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
EasyUnsubscribe: http://lists.mulberrytech.com/unsub/xsl-list/1167547
or by email: xsl-list-unsub(_at_)lists(_dot_)mulberrytech(_dot_)com
--~--

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