This is the mail archive of the xsl-list@mulberrytech.com mailing list .


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Formatting CDATA information


> I am using an XSL stylesheet to format and XML document into an HTML
> document.  In the XML document there is a CDATA tag as follows:
> 
> <failure type="junit.framework.AssertionFailedError">
> 			 <![CDATA[ 
> 					junit.framework.AssertionFailedError
> 						at
> junit.framework.Assert.fail(Assert.java:143)
> 						at
> junit.framework.Assert.assert(Assert.java:19)
> 			  ]]> 
> </failure>
> 
> Here is my XSL:
> 
> <xsl:template match="failure">
> 	<p>FAILURE INFO:</p>
> 	<xsl:value-of select="."/>
> </xsl:template>
> 
> The problem is that when this gets converted to HTML all of the line
> breaks in the CDATA section are lost, and it becomes one long line.  Is
> there a way to format what's inside the CDATA tag to have <br> after each
> line?
> 
> Thanks.

 XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]