Altova Mailing List Archives>Archive Index >comp.text.xml Archive Home >Recent entries >Thread Prev - Help - I'm losing newline when performing XSL Transform >Thread Next - Re: Help - I'm losing newline when performing XSL Transform Re: Help - I'm losing newline when performing XSL TransformTo: NULL Date: 10/2/2005 12:16:00 AM jjouett said the following on 2005-10-01 23:40 +0200: > I'm trying to preserve the newline characters in my transformed XML > (read from a file) to provide a meaningful line number when validation > errors occur. However, my current method which performs an XSL > transform prior to validation is removing all the newlines. The XSL is > simply adding a namespace: I'm fairly new to XML and XSL(T), but have you tried adding: <xsl:output method="xml" indent="yes> .. to your xsl file? http://www.w3.org/TR/xslt#output There are also some notes on white space handling for xsl and xml which might be of interest, but I think the indent attribute solves your newline problem: http://www.w3.org/TR/xslt#strip http://www.w3.org/TR/REC-xml/#sec-white-space -- Regards Harrie | ||||||
| Company | Legal | Press | Partners | Careers | Sitemap | Contact Us | Altova Blog | Mobile | Full Site | |||
|
