incubator-jspwiki-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Christophe Dupriez" <>
Subject Internationalization of GOT IT!
Date Thu, 24 Jan 2008 15:48:54 GMT
Hi Pål!

The output of tidy already contains question marks in place of M$ characters:

I tried to add switches to JTidy:
        Tidy tidy = new Tidy();
        tidy.setCharEncoding(3);  -- 3 = UTF-8 in JTidy R7
        Document xmlDocument = tidy.parseDOM(in, null);
But it was not enough. The real solution implies (also?) to set the encoding of JTidy input
string to "UTF-8" and NOT to the encoding of the HTTP response (which is here ISO-8859-1).
Response encoding seems to be ignored by PDF readers but probably has to be set to "UTF-8"
        InputStream in = new ByteArrayInputStream(("<title>" + nameOfPage + "</title>"
+ htmlOfPage)

Please find herewith the modified source code. I would deeply appreciate that you publish
a new JAR as it would permit me to normalize my setting (I currently patch the Jar with the
compiled class!)

Have a nice evening!

Christophe Dupriez
  • Unnamed multipart/mixed (inline, None, 0 bytes)
View raw message