Re: [xsl] Removing white space from XML file

Subject: Re: [xsl] Removing white space from XML file
From: "Rashmi Rubdi" <rashmi.sub@xxxxxxxxx>
Date: Wed, 11 Apr 2007 23:06:17 -0400
On 4/11/07, Chad Chelius <cchelius@xxxxxxxxxxxxxxx> wrote:
be one space instead of several. I know this can be accomplished with
a find change in many programs, but it would be great if I could
remove these extra spaces using an XSLT.

I think if you set indent="no" in the xsl:output tag of your XSL, it removes all the extra white spaces between the XML nodes (I tested this a while ago, if my memory is right then it should work).

<xsl:output method="xml" omit-xml-declaration="no" indent="no"/>

If you know Ant, another way to remove extra white spaces is with
Apache Ant Build.
as shown in the example here:


Current Thread