This is the mail archive of the xsl-list@mulberrytech.com mailing list .


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

RE: variable in xpath?


At 04:44 PM 4/11/2002, you wrote:
>I will give it a try, but could someone comment on the predicate within 
>predicate syntax used here? It is very
>rare - I never saw it beofre
>
>>    select="element[*[name()=$child and . = $value]]"
>>or:
>>    select="*[*[name()=$child and . = $value]]"

   Just read it out loud:
   "Select every node named 'element' that itself has a node named $child 
and the value of that child node is $value."

   In psuedo-xml, it would select all "element" nodes that looked like
<element>
   <$child>$value</$child>
</element>

   The outer predicate is a condition on which element objects to 
select.  The inner predicate is a condition on which children of element to 
select (as a basis for selecting the parent itself).



Greg Faron
Integre Technical Publishing Co.



 XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]