[jboss-jira] [JBoss JIRA] Commented: (JBFORUMS-247) forums and commons-fileupload-1.1
Ryszard Kozmik (JIRA)
jira-events at lists.jboss.org
Wed Oct 31 22:23:45 EDT 2007
[ http://jira.jboss.com/jira/browse/JBFORUMS-247?page=comments#action_12385459 ]
Ryszard Kozmik commented on JBFORUMS-247:
-----------------------------------------
Indeed it helps for à, è, ì, ò, ù but it e.g. doesn't for Polish diacritical characters like ź,ć,ę,ż,ł,ą,ś,ń. (I have URIEncoding="UTF-8" in my 8080 connector in server.xml of tomcat). Do you have any idea what can be wrong?
> forums and commons-fileupload-1.1
> ---------------------------------
>
> Key: JBFORUMS-247
> URL: http://jira.jboss.com/jira/browse/JBFORUMS-247
> Project: JBoss Forums
> Issue Type: Bug
> Components: Portlet Productization, Forum Model Layer
> Environment: JBoss as from http://anonsvn.jboss.org/repos/jbossas/tags/JBoss_4_0_5_GA_CP06,
> JBoss Portal from http://anonsvn.jboss.org/repos/portal/trunk since 9 july 2007,
> JBoss Forums from http://anonsvn.jboss.org/repos/labs/labs/jbossforums/branches/forums101P26 since 9 july 2007
> Reporter: Luca Stancapiano
> Assigned To: Ryszard Kozmik
> Fix For: 1.0.1 RC
>
> Attachments: ForumsJSFPortlet.java, patch_multiple_forums_src_1.1.0_30_sep_2007.zip
>
>
> hi....I send you to see http://jira.jboss.com/jira/browse/JBPORTAL-1550 by me reported. It is the same problem......if you post messages using 'multipart/form-data' through commons-fileupload libs, you miss character encoding because there is a incompatibility between tomcat 5.5.23 and fileupload 1.1, and then if you try to send messages with characters as à, è, ì, ò, ù you 'll get problems of decoding with strange characters of response. Also for Forums I send you a patch. I substituted getString() method of org.apache.commons.fileupload.disk.DiskFileItem class with getString( String ...) method, passing inside the character encoding of the request:
> org.jboss.portlet.forums.ui.ForumsJSFPortlet : row 560
> I write :
>
> newParams.put(item.getFieldName(), new String[]{item.getString(req.getCharacterEncoding())});
> instead of:
> newParams.put(item.getFieldName(), new String[]{item.getString()});
> org.jboss.portlet.forums.ui.ForumsJSFPortlet : row 564
>
> I write:
> String value = item.getString(req.getCharacterEncoding());
> instead of:
> String value = item.getString();
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.jboss.com/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
More information about the jboss-jira
mailing list