[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message]

how do I retrieve element node by predicating attribut

Subject: how do I retrieve element node by predicating attribute value
From: Ming Fang <ming.fang@xxxxxxxxxxx>
Date: Mon, 12 Aug 2002 12:40:40 -0400
xsl retrieving element name
I'm trying to create a stylesheet that would filter out the specific
attribute value by predicating method, and return the 
element node name that holds the specific attribute value.  An example of
this problem would be clarify my problem that
I'm trying to present.

   <porsche maker="German"> pure racing </porsche>
   <lexus     maker="Japan"> luxury </lexus> 
   <ford       maker="USA"> economy</ford>
   <jaguar    maker="UK">high-end luxury	<jaguar>

in my snippet stylesheet, I would like to test the case for attribute value
that is 'German' and get return of 'porsche' as the element name, how do I
approach this problem?

<xsl:if test="//*[@maker = 'German'] ">
  <!-- how would I retrieve element name 'porsche' -->
  <xsl:value-of select=????/>


Confidentiality Notice: This email and any files transmitted with it are
confidential and are intended solely for the use of the individual or entity
to whom they are addressed. If you are not the original recipient or the
person responsible for delivering the email to the intended recipient, be
advised that you have received this email in error, and that any use,
dissemination, forwarding, printing, or copying of this email is strictly
prohibited. If you received this email in error, please notify the
originator immediately.

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

Current Thread


Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced!

Buy Stylus Studio Now

Download The World's Best XML IDE!

Accelerate XML development with our award-winning XML IDE - Download a free trial today!

Don't miss another message! Subscribe to this list today.
First Name
Last Name
Subscribe in XML format
RSS 2.0
Atom 0.3
Site Map | Privacy Policy | Terms of Use | Trademarks
Free Stylus Studio XML Training:
W3C Member
Stylus Studio® and DataDirect XQuery ™are products from DataDirect Technologies, is a registered trademark of Progress Software Corporation, in the U.S. and other countries. © 2004-2013 All Rights Reserved.