xsl-list
[Top] [All Lists]

WhiteSpace

2003-11-06 07:38:47
Hello All,

When I apply the below template to my xml I get 
 in place of white
space.  How do can I remove the &#xA;?  I thought <xsl:strip-space> would
romove the hard spaces in the xml.


###########Template Used##########

<?xml version="1.0" encoding="UTF-8"?>
<xsl:stylesheet version="1.0"
xmlns:xsl="http://www.w3.org/1999/XSL/Transform";>
<xsl:output method="xml" version="1.0" encoding="UTF-8" indent="yes"/>
<xsl:strip-space elements="*"/>
 

<xsl:template match="/ | node() | @* | comment() |
processing-instruction()">
  <xsl:copy>
    <xsl:apply-templates select="@* | node()"/>
  </xsl:copy>
</xsl:template>
   
</xsl:stylesheet>

########### XML #################
<?xml version="1.0" encoding="UTF-8"?>
<BODY>
                <P style="font-size:12.0">
                        <SPAN style="font-family:'Times New Roman','Times
New Roman',Serif;
 font-size:12.0pt;
 font-style:normal;
 font-weight:bold;
 font-stretch:normal;
 font-variant:normal;
 color:#000000">CHAPTER 2 </SPAN>
                </P>
        <P style="font-size:12.0">
                        <SPAN style="font-family:'Times New Roman','Times
New Roman',Serif;
 font-size:12.0pt;
 font-style:normal;
 font-weight:bold;
 font-stretch:normal;
 font-variant:normal;
 color:#000000">TITLE </SPAN>
                </P>
</BODY>


############# OUTPUT ################

<BODY>
        <P style="font-size:12.0">
                <SPAN style="font-family:'Times New Roman','Times New
Roman',Serif;&#xA; font-size:12.0pt;&#xA; font-style:normal;&#xA;
font-weight:bold;&#xA; font-stretch:normal;&#xA; font-variant:normal;&#xA;
color:#000000">CHAPTER 2 </SPAN>
        </P>
        <H1 style="font-size:12.0">
                <SPAN style="font-family:'Times New Roman','Times New
Roman',Serif;&#xA; font-size:12.0pt;&#xA; font-style:normal;&#xA;
font-weight:bold;&#xA; font-stretch:normal;&#xA; font-variant:normal;&#xA;
color:#000000">TITLE </SPAN>
</BODY>

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



<Prev in Thread] Current Thread [Next in Thread>