Hi Matthew,

Could you please post a minimal xml document and stylesheet that reproduces
the problem?  We can't really debug anything without that.  If possible,
have your mailer is send plain text, not html/rich text.

Also, I think your message is getting munged through mailing, so I'm having
a hard time figuring out the "pertinent output" part of your message.  Can
you provide a prose description of the problem?

A couple of things to try:

   1. Specify text as the method attribute on an xsl:output element, and
   don't use the -text option.

   2. Specify an encoding that is appropriate for your target system, again
   using xsl:output.  Without an encoding, the processor will use UTF-8,
   which is probably correct, but may not look correct, depending on your
   system and the tools you're using.  The degree sign (U+00B0) will be
   encoded as two bytes in UTF-8 (C2 B0), which is probably why you're
   seeing the two characters � and �.

   For example, ISO-8859-1(Latin-1) might be appropriate, or perhaps one of
   Windows' encodings, like Windows-1252, or even ASCII, if you don't might
   getting the degree sign as a numeric character reference.

   <xsl:output method="text" encoding="ISO-8859-1"/>

Dave



                                                                                       
      
                    "Matthew L.                                                        
      
                    Avizinis"            To:     <[EMAIL PROTECTED]>            
      
                    <[EMAIL PROTECTED]        cc:     (bcc: David N Bertoni/CAM/Lotus)      
      
                    m>                   Subject:     unusual output for Xalan C++     
      
                                                                                       
      
                    07/05/2001                                                         
      
                    10:10 AM                                                           
      
                    Please                                                             
      
                    respond to                                                         
      
                    xalan-dev                                                          
      
                                                                                       
      
                                                                                       
      



The following text is sent to the below template. I am using Xalan C++
1.1.0 testXSLT.exe.

A private pilot flying a magnetic heading of 185&deg; on a VFR cross
country flight tracking outbound on the 177&deg; radial of a VOR above
3,000 ft. AGL should maintain an odd, not even, thousand ft. MSL altitude
plus 500 ft., e.g., 5,500 ft. MSL (14 CFR Sec. 91.155).

TEMPLATE:


<xsl:template name="TextOut">


<xsl:param name="text"/>


<xsl:variable name="apos">&apos;</xsl:variable>


<xsl:variable name="ntext" select="$text"/>


<xsl:choose>


<xsl:when test="contains($text,$apos)">


<xsl:variable name="first" select="substring-before($ntext,$apos)"/>


<xsl:variable name="rest-of-it" select="substring-after($ntext,$apos)"/>


<xsl:value-of select="concat($first,'\',$apos)"/>


<xsl:if test="$rest-of-it">


<xsl:call-template name="TextOut"><xsl:with-param name="text" select="
$rest-of-it"/></xsl:call-template>


</xsl:if>


</xsl:when>


<xsl:otherwise>


<xsl:value-of select="$text"/>


</xsl:otherwise>


</xsl:choose>


</xsl:template>





pertinent OUTPUT:  .... °  ....


I think it should not be emitting this character twice.  Else am I doing
something incorrectly? (This program has otherwise functioned exceptionally
well.)


also: using the -text option


thanks,


  Matthew L. Avizinis
Gleim Publications, Inc.
   4201 NW 95th Blvd.
 Gainesville, FL 32606
(352)-375-0772 ext. 101
     www.gleim.com







Reply via email to