[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message] Re: Select attribute using a variable
strawks wrote:
You cannot do it like this, as XSLTProc is saying: it is a syntax error (after the double colon should be a node name (QName) not a variable name). Instead, if you want to check the name of an attribute and then select that attribute, try this: select="/document/styles/style[@name=$style_name]/@*[name() = $property]" If there are more <style> nodes with an attribute "name" with the value of $style_name, this may return more than one attribute, depending on the XSLT version. If you need to do something for each <style>, use templates instead of an absolute XPath. HTH Cheers, -- Abel Braaksma
|
PURCHASE STYLUS STUDIO ONLINE TODAY!Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced! Download The World's Best XML IDE!Accelerate XML development with our award-winning XML IDE - Download a free trial today! Subscribe in XML format
|