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

Re: Updating Attribute Values

Subject: Re: Updating Attribute Values
From: Martin Holmes <mholmes@xxxxxxx>
Date: Thu, 15 Aug 2013 08:07:03 -0700
Re:  Updating Attribute Values
Hi there,

The usual answer to this is "namespaces". I don't know what namespace the <dao> element is in, but the way your template is written assumes that it's in the default namespace for the transformation (usually defined with @xpath-default-namespace. If not, you probably need to create a namespace prefix for it.

If that's not it, then we should probably see the rest of your transformation file. I did notice that you're using XSLT 2.0 with Saxon 6.5.5, which is not a good idea; for XSLT 2.0, use Saxon 9x if you can.

Cheers,
Martin

On 13-08-15 07:41 AM, Nathan Tallman wrote:
I'd like to change the values of attribute "href", whenever it appears
inside a "dao" element. From what I can tell, my template is correct,
however when ever I stick anything inside xsl:attribute (replace <!--
do stuff here -->, nothing happens during the transformation. Am I
missing something?

     <xsl:template match="@href[parent::dao]">
         <xsl:attribute name="href">
             <!-- do stuff here -->
         </xsl:attribute>
     </xsl:template>

I'm using XSLT 2.0, Saxon 6.5.5.

Thanks,
Nathan

.


-- Martin Holmes University of Victoria Humanities Computing and Media Centre (mholmes@xxxxxxx)

Current Thread

PURCHASE STYLUS STUDIO ONLINE TODAY!

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.
Email
First Name
Last Name
Company
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.