
Hi, The following is based on this question here: http://stackoverflow.com/questions/28398651/how-to-generate-markup-inside-of... What I ended up using in my XSLT stylesheet was something along these lines: <xsl:attribute name="bla"> <![CDATA[Here is <em>some</em>verbatim text with id="]]> <xsl:value-of select="@id"/> <![CDATA[" and <strong>more</strong> stuff.]]> </xsl:attribute> This worked reliably. However, this worked only after a seemingly subtle fix to the text itself! Initially I had something like id-<xsl:value-of select="@id"/> i.e. there was some text before that <xsl:value>. This worked sometimes, but not others where suddenly the CDATA following that text/element combination was swallowed away. Removing any text around the <xsl:value> seems to work in all cases though. Unfortunately, the document is too large to send and I don't really have the time to build a small test case which illustrates this problem. But it seems to me that there is a parser issue here when multiple CDATA inside of the <xsl:attribute> were combined with text and another element like <xsl:value>. There was no error message, just garbled output. Cheers, Jens -- Jens Tröger http://savage.light-speed.de/