<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD>
<META http-equiv=Content-Type content="text/html; charset=iso-8859-1">
<META content="MSHTML 6.00.2800.1400" name=GENERATOR>
<STYLE></STYLE>
</HEAD>
<BODY bgColor=#ffffff>
<DIV><FONT face=Arial size=2>Hi,</FONT></DIV>
<DIV><FONT face=Arial size=2></FONT> </DIV>
<DIV><FONT face=Arial size=2>We are using a small form for uploading files with
one text filed:</FONT></DIV>
<DIV><FONT face=Arial size=2></FONT> </DIV>
<DIV><FONT face=Arial size=2><form name="send" method="post"
action="some.jsp" enctype="multipart/form-data"></FONT></DIV>
<DIV><FONT face=Arial size=2> </FONT></DIV>
<DIV><FONT face=Arial size=2> <br><BR> <textarea
cols="80" rows="30" name="content"><BR> Type your
text here.</FONT></DIV>
<DIV><FONT face=Arial
size=2> </textarea><BR> <br><br><BR> <input
type=file name=attachment><BR> <br><br><BR>
<input type=Submit value=Send></FONT></DIV><FONT face=Arial size=2>
<DIV><BR></form></DIV>
<DIV> </DIV>
<DIV>Jsp page with this form has a content-encoding property set to UTF-8 and
jsp page specified in action, too. When I want to get text from textarea I use
this piece of code:</DIV>
<DIV> </DIV>
<DIV>CmsJspActionElement cms = new CmsJspActionElement(pageContext, request,
response);</DIV>
<DIV>String content =
cms.getRequestContext().getRequest().getParameter("content");</DIV>
<DIV> </DIV>
<DIV>My problem is that I don't have UTF-8 characters in String variable
content. With uploaded file everything is fine. I try to
setCharacterEncoding("UTF-8") on request object before initialize
CmsJspActionElement but there was no results. So, when I send some Cyrillic's
content with file I've got something like this:
дÑÑ
гÑдÑ
гÑдÑ
гÑд.</DIV>
<DIV> </DIV>
<DIV>We use OpenCms5.0.0 (set to UTF-8), WinXP, MySql 4.0.15, Tomcat 4.1.24LE
(with -Dfile.encoding=UTF-8) and JDK 1.4.2_03.</DIV>
<DIV> </DIV>
<DIV>Please, help.</DIV>
<DIV> </DIV>
<DIV>Best regards,</DIV>
<DIV>Ivan Jelenic</DIV>
<DIV><A href="mailto:ivan.jelenic@nbs.yu">ivan.jelenic@nbs.yu</A>
</FONT></DIV></BODY></HTML>