You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@struts.apache.org by bu...@apache.org on 2002/07/04 08:31:24 UTC
DO NOT REPLY [Bug 10464] New: -
other than ISO-8859-1 encodings don't work in forms that contain upload fields
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
<http://nagoya.apache.org/bugzilla/show_bug.cgi?id=10464>.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND
INSERTED IN THE BUG DATABASE.
http://nagoya.apache.org/bugzilla/show_bug.cgi?id=10464
other than ISO-8859-1 encodings don't work in forms that contain upload fields
Summary: other than ISO-8859-1 encodings don't work in forms that
contain upload fields
Product: Struts
Version: 1.0.2 Final
Platform: All
OS/Version: Windows XP
Status: NEW
Severity: Normal
Priority: Other
Component: File Upload
AssignedTo: struts-dev@jakarta.apache.org
ReportedBy: mvirt@mail.ru
I try to use windows-1251 encoding in my pages and if the form contains upload
field <html:file/>, fields with non-latin characters are wrong decoded -
result string contains '?' symbols instead of national symbols.
solution:
- org.apache.struts.upload.MultipartIterator
- method: readLine(), last line of the method is:
return new String(bufferByte, 0, bytesRead, "ISO-8859-1");
should be replaced with:
String encoding = request.getCharacterEncoding();
if(encoding == null)
encoding = "ISO-8859-1";
return new String(bufferByte, 0, bytesRead, encoding);
regards
Maxim Wirt
--
To unsubscribe, e-mail: <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>