unable to post unicode characters in struts bridge
--------------------------------------------------

         Key: PB-14
         URL: http://issues.apache.org/jira/browse/PB-14
     Project: Portals Bridges
        Type: Bug
  Components: struts  
    Versions: 0.4    
    Reporter: Thorsten Berger


Using struts forms to post unicode characters (e.g. german umlauts) results in 
a String with garbage characters.
I urgently need this to work for my portal, so I tracked down the problem and 
found it to be specific to Jetspeed.
I logged a JIRA issue for jetspeed, but maybe this problem also exists when 
using the struts bridge with another portal.

The main cause is decoding request parameters twice in 
o.a.j.engine.servlet.ServletRequestImpl (line 157):

                     try
                        {
                            paramValues[i] = new 
String(paramValues[i].getBytes("ISO-8859-1"), getCharacterEncoding());
                        }
                        catch (UnsupportedEncodingException e)
                        
This is called firstly by jetspeed itself (providing parameters to the 
StrutsPortlet) and secondly by the Struts RequestProcessor (to populate the 
form bean). It's clear that this results in garbage characters.
However, I don't think it's a struts bridge bug. For further explanation and a 
solution for Jetspeed, see JS2-376 (request parameter encoding problem)

Regards, Thorsten


-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to