cocoon-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Torsten Curdt <tcu...@apache.org>
Subject Re: encoding problem in textarea
Date Fri, 03 Dec 2004 14:47:06 GMT
Mate,

I am not totally sure but...

> Technique:
> I read the XML Source to a String (to add to the textarea widget) like  
> this:
> 
> var string = org.apache.avalon.excalibur.io.IOUtil.toString(
>   new java.io.BufferedInputStream(
>     org.apache.cocoon.components.source.SourceUtil.getInputSource(
>       resolver.resolveURI(uri)
>     ).getByteStream()
>   )
> );

if you create a String from a byte stream, array or
whatever is byte-based don't you have to specify the
charset? AFAIK creating a String from a byte array
uses the platform default charset.

> form.lookupWidget("xhtml").setValue(string);

did you check whether the string looks fine here?

...just what came up to my mind right away

HTH

cheers
--
Torsten

Mime
View raw message