Subject: Re: [xsl] May be fun for you .... From: daniel whitney <dbf.whitney@xxxxxxxxx> Date: Mon, 16 May 2011 23:51:19 -0400 |
My apologies On Mon, May 16, 2011 at 6:48 PM, Tommie Usdin <btusdin@xxxxxxxxxxxxxxxx> wrote: > You write "Haven't posted here in a while" so I will forgive your blatant disregard of the XSL-List requirement for informative subject lines. This time. > > In your future postings to XSL-List please provide an informative title or subject line. Good subject lines - those that describe the subject matter of your message - not only increase the chances that you will receive answers to questions or responses to comments, they also make your message and any replies to it accessible in the list archives. > > In this case "Puzzle with special characters" would have been better than "May be fun for you ...." (which is totally uninformative), and "Confusion between encoding and version" may have been better yet. > > -- Tommie Usdin > XSL-List Owner > > > > On May 16, 2011, at 3:56 PM, daniel whitney wrote: > >> Haven't posted here in a while, but here's something that had me >> baffled. A co-worker came to me and said that she was converting XML >> to text and couldn't understand why her special characters were coming >> out with a strange character in front of them. I did a transform using >> Saxon 6.5.3 and sure enough the output was like this: >> >> B%3,000,000<tab>B%3,000,000 >> B#30,000<tab>B#23,250 >> >> That's an easy one, I thought, she's outputting UTF. I quickly checked >> the encoding, saw iso-8859-1 - that wasn't the problem. Checked the >> rest of the XSL files, they appeared fine. Checked the XML file, >> seemed fine as well. Pulled both the XSL and XML into a hex editor, >> see if there was some funny hidden character. Nothing. Was turning >> into a real head scratcher. Desperate times called for desperate >> measure - so thinking outside of the box, and daring the unthinkable, >> I changed the output method from "text" to "xml". Of course the same >> problem. At this point I was running out of options. I showed the >> co-worker the transformed XML file, explaining to her that everything >> looked fine, when I got my first clue: the XML declaration showed: >> <?xml version="iso-8859-1" encoding="utf-8"?>. Very strange ... Going >> back to the XSL file I saw the problem. The <xsl:output element looked >> like this: <xsl:output method="text" indent="yes" >> version="iso-8859-1"/>. Of course in my zeal to find the quick answer >> and prove my XML expertise, I saw the iso-8859-1 attribute value but >> didn't bother checking the attribute itself. >> >> I'm sure there's some witty moral to this story ... anyone. For my >> part ... details - Details - DETAILS. >> >> Dan >> > > ====================================================================== > B. Tommie Usdin mailto:btusdin@xxxxxxxxxxxxxxxx > Mulberry Technologies, Inc. http://www.mulberrytech.com > 17 West Jefferson Street Phone: 301/315-9631 > Suite 207 Direct Line: 301/315-9634 > Rockville, MD 20850 Fax: 301/315-8285 > ---------------------------------------------------------------------- > Mulberry Technologies: A Consultancy Specializing in SGML and XML > ======================================================================
Current Thread |
---|
|
<- Previous | Index | Next -> |
---|---|---|
Re: [xsl] May be fun for you ...., Tommie Usdin | Thread | [xsl] preserve structure of input X, a kusa |
Re: [xsl] May be fun for you ...., Tommie Usdin | Date | [xsl] preserve structure of input X, a kusa |
Month |