Categories: MSDN / DotNet / Java / Scripts / Linux / PHP Ask - La ask - La Answer

XSLT: Dynamic Concatenation of XHTML sections?

I need to transform an XML file that looks like this:

<paragraph_section>
<div>This is some text with <em>italicized</em> words.</div>
</paragraph_section>

into this XHTML output:

<div><strong>A generic string of strong text.</strong> This is some text with <em>italicized</em> words.</div>

It seems really simple, but I'm not seeing it. I need to preserve any formatting tags within the <div> section, so something like this:

<xsl:template match = "paragraph_section">
<div><strong>A generic string of strong text.</strong> <xsl:value-of select="."/></div>
</xsl:template>

will not work, as it would output this:

<div><strong>A generic string of strong text.</strong> This is some text with italicized words.</div>

Any suggestions?
[973 byte] By [anotherchrisber] at [2007-11-11 7:52:54]