PQ72756: UTF-8 text, such as Japanese, retrieved from a JSP input field or passed as a jsp:param gets corrupted. | |||||||||||||||||||||||||||||||||||||||||||||||
![]() |
|||||||||||||||||||||||||||||||||||||||||||||||
![]() APAR status Closed as program error. Error description The original PMR was reported as a problem with Japanese characters as is used in the following problem description. 1. The application uses text areas and text input fields in a form in a JSP to capture input. The JSP uses the JSP standard actions jsp:useBean and jsp:setProperty to store and retrieve the input from the java bean. The JSP page encoding is set using the following page directive. <%@ page language="java" contentType="text/html; charset=UTF-8" %> The Japanese text input is returned as garbled text. Setting the request encoding in the JSP , <% request.setCharacterEncoding("UTF-8"); %>, or setting the WebSphere System Property client.encoding.override=UTF-8 resolves this problem. 2. The application also uses the jsp:include and jsp:param standard actions where the value of the param can be a Japanese text string. The JSP page encoding is set using the following page directive. <%@ page language="java" contentType="text/html; charset=UTF-8" %> If the request encoding in the JSP is set, <% request.setCharacterEncoding("UTF-8"); %>, or the WebSphere System Property client.encoding.override=UTF-8 is set, aLocal fix Japanese t xt string set as the value of the jsp:param becomes ?? when retrieved using request.getParameter. If request.setCharacterEncoding("UTF-8") is not set or the System Property for UTF-8 override is not set, request.getParameter returns the text correctly. The test case uses request.getParameter to retrieve the string set by jsp:param. The application uses this as well as jsp:setProperty property=* and then retrieves the property from a bean. This has the same problem. LOCAL FIX:ン noneProblem summary **************************************************************** * USERS AFFECTED: WebSphere Application Server Developers * * using DBCS characters in the JSP input field * * and request parameters. * **************************************************************** * PROBLEM DESCRIPTION: DBCS character retrieved from input * * field on JSP garbled and DBCS text * * passed as request parameter in JSP * * garbled * **************************************************************** * RECOMMENDATION: * **************************************************************** If a JSP page encoding is set using the following <%@ page language="java" contentType="text/html; charset=UTF-8" %>, the DBCS text input is returned as garbled text if the JSP uses the JSP standard actions jsp:useBean and jsp:setProperty to store and retrieve the input from the java bean. Also a DBCS text string set as the value of the jsp:param becomes ?? when retrieved using request.getParameter.Problem conclusion To prevent garbled DBCS text, during internal input parse on QueryString, the jsp dipatcher will not parse the input specified in the user encoding format.Temporary fix ZE FIX ERROR PQ74501 02/05/22 The PQ72756_test fix is up on PQ99999, please test itComments
APAR is sysrouted FROM one or more of the following: APAR is sysrouted TO one or more of the following: Modules/Macros
Publications Referenced
|
Product categories: Software > Application Servers >
Distributed Application & Web Servers > WebSphere Application
Server > General
Operating system(s):
Software version: 00W
Software edition:
Reference #: PQ72756
IBM Group: Software Group
Modified date: May 22, 2003
(C) Copyright IBM Corporation 2000, 2008. All Rights Reserved.