[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message] RE: xsl transform question
> I am trying to create another xsl after processing one xsl. > The reason I need this because the element "name" will be > availabale in another xml. In the first xsl, I have s/th like this : > > <xsl:attribute name="value"><xsl:text > disable-output-escaping="yes"><![CDATA[<xsl:value-of > select="name"/>]]></xsl:text></xsl:attribute> > > The output of this in my new xsl is : > value="<xsl:value-of select="name"/>" > > I want it to be like : > value="<xsl:value-of select="name"/>" > because then only it would be a valid xsl. Why are you trying to generate invalid XML? XML does not allow elements to appear within attributes. It is an error (in XSLT 1.0) to use disable-output-escaping for text within an attribute node. In 2.0 (if you really need to produce invalid XML) you can do it using <xsl:attribute disable-output-escaping="yes">. It is also an error in 1.0 to have any instructions within <xsl:text> Michael Kay Software AG home: Michael.H.Kay@xxxxxxxxxxxx work: Michael.Kay@xxxxxxxxxxxxxx XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
|
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
|