Question

Markdown formatting is coming into my XSL and maintaining its whitespace and breaks. I want it to be converted to actual HTML elements to remove all whitespace.

Here's a look at the incoming data & HTML source, and here's the code used to process it..

<xsl:value-of select="description-continued" disable-output-escaping="yes" />

The XSL output method already contains indent="no"

Was it helpful?

Solution 2

<xsl:value-of select="normalize-space(description-continued)" disable-output-escaping="yes" />

OTHER TIPS

You may just need (in case no group of whitespace characters really matters):

<xsl:template match="text()">
 <xsl:value-of select="normalize-space()"/>
</xsl:template>
Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top