Author: kenfinni
Date: 2012-02-01 10:28:25 -0500 (Wed, 01 Feb 2012)
New Revision: 8346
Modified:
epp/portal/branches/EPP_5_2_Branch/component/web/controller/src/main/java/org/exoplatform/web/WebAppController.java
Log:
JBEPP-1428: Unicode characters handling problem
- Set Character encoding to UTF-8 before any Request parameters are accessed
Modified:
epp/portal/branches/EPP_5_2_Branch/component/web/controller/src/main/java/org/exoplatform/web/WebAppController.java
===================================================================
---
epp/portal/branches/EPP_5_2_Branch/component/web/controller/src/main/java/org/exoplatform/web/WebAppController.java 2012-02-01
14:54:02 UTC (rev 8345)
+++
epp/portal/branches/EPP_5_2_Branch/component/web/controller/src/main/java/org/exoplatform/web/WebAppController.java 2012-02-01
15:28:25 UTC (rev 8346)
@@ -309,6 +309,17 @@
public void service(HttpServletRequest req, HttpServletResponse res) throws Exception
{
boolean debug = log.isDebugEnabled();
+
+ try
+ {
+ // We set the character encoding now to UTF-8 before obtaining parameters
+ req.setCharacterEncoding("UTF-8");
+ }
+ catch (UnsupportedEncodingException e)
+ {
+ log.error("Encoding not supported", e);
+ }
+
String portalPath = req.getRequestURI().substring(req.getContextPath().length());
Router router = routerRef.get();
Show replies by date