OK, thank you very much Does it "re-encode" the text using 2 bytes per char as with real UTF encoding?
Simone ------------------------- Simone Chiaretta www.piyosailing.com/S Any sufficiently advanced technology is indistinguishable from magic "Life is short, play hard" > -----Messaggio originale----- > Da: news [mailto:[EMAIL PROTECTED] Per conto di Bill Barker > Inviato: sabato 12 giugno 2004 7.19 > A: [EMAIL PROTECTED] > Oggetto: Re: How to implement setCharacterEncoding in Tomcat 4.1.x > > > You can use: > response.setContentType("text/xml; charset=utf-8"); > This works for TC 3-5. > > "Simone - Dev" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > Hello all, > I made a servlet that generates a XML response that must be in UTF-8 > because it can include any type of chars (Jap, Arabs, chinese, russian > and so on) I developed it on Tomcat 5.0.x and I used, to set the > correct encoding, the method setCharacterEncoding before calling the > out.getWriter and everything works fine. > > But a developer (this servlet is part of an open source project > available on sf.net) said that with tomcat 4.1.x it doesn't work > (raise a NoSuchMethodError). I looked at the tomcat 4.1.x javadoc and > saw that this method is not implemented since tomcat 5.0.x > > Since I'd like to support 4.1.x too how can I do to obtain the same > functionality? > > Thank you > Simone > > ------------------------- > Simone Chiaretta > <http://www.piyosailing.com/S> www.piyosailing.com/S > Any sufficiently advanced technology is indistinguishable from magic > "Life is short, play hard" > > --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
