Author: phuong_vu
Date: 2011-10-13 06:20:10 -0400 (Thu, 13 Oct 2011)
New Revision: 7739
Modified:
portal/trunk/component/web/server/src/main/java/org/exoplatform/upload/UploadService.java
Log:
GTNPORTAL-2156 broken display name when upload a file with French language
Modified:
portal/trunk/component/web/server/src/main/java/org/exoplatform/upload/UploadService.java
===================================================================
---
portal/trunk/component/web/server/src/main/java/org/exoplatform/upload/UploadService.java 2011-10-13
08:31:33 UTC (rev 7738)
+++
portal/trunk/component/web/server/src/main/java/org/exoplatform/upload/UploadService.java 2011-10-13
10:20:10 UTC (rev 7739)
@@ -19,19 +19,6 @@
package org.exoplatform.upload;
-import java.io.File;
-import java.io.FileOutputStream;
-import java.io.InputStream;
-import java.util.ArrayList;
-import java.util.HashSet;
-import java.util.LinkedHashMap;
-import java.util.List;
-import java.util.Map;
-import java.util.Set;
-
-import javax.servlet.http.HttpServletRequest;
-import javax.servlet.http.HttpSession;
-
import org.apache.commons.fileupload.FileItem;
import org.apache.commons.fileupload.FileUploadException;
import org.apache.commons.fileupload.ProgressListener;
@@ -44,6 +31,17 @@
import org.gatein.common.logging.LoggerFactory;
import org.gatein.common.text.EntityEncoder;
+import java.io.File;
+import java.util.ArrayList;
+import java.util.HashSet;
+import java.util.LinkedHashMap;
+import java.util.List;
+import java.util.Map;
+import java.util.Set;
+
+import javax.servlet.http.HttpServletRequest;
+import javax.servlet.http.HttpSession;
+
public class UploadService
{
/** . */
@@ -258,6 +256,7 @@
// Create a new file upload handler
ServletFileUpload upload = new ServletFileUpload(factory);
+ upload.setHeaderEncoding("UTF-8");
ProgressListener listener = new ProgressListener()
{
public void update(long pBytesRead, long pContentLength, int pItems)
Show replies by date