Mantis - Resin
|
|||||
Viewing Issue Advanced Details | |||||
|
|||||
ID: | Category: | Severity: | Reproducibility: | Date Submitted: | Last Update: |
6160 | minor | always | 05-02-18 13:17 | 05-02-18 15:13 | |
|
|||||
Reporter: | wileysaw | Platform: | |||
Assigned To: | ferg | OS: | |||
Priority: | normal | OS Version: | |||
Status: | closed | Product Version: | 4.0.55 | ||
Product Build: | Resolution: | no change required | |||
Projection: | none | ||||
ETA: | none | Fixed in Version: | |||
|
|||||
Summary: | 0006160: <character-encoding> not set with @include in JSP pages | ||||
Description: |
We have many pages with Spanish text that include a common header file. For example, page1.jsp has <%@include file=”header.jsp” %>, which is followed by String literals in Spanish. header.jsp includes a page directive to set the charset to UTF-8. <%@page contentType="text/html; charset=UTF-8" %>. This worked fine in Resin 3. In Resin 4, the Spanish accented text will be displayed incorrectly. However, if I place the page directive in page1.jsp, then it will work. Regardless where the page directive is, in the generated java file, this same line is added: response.setContentType(“text/html; charset=UTF-8”); Looking at the encoded literals, it looks like ISO-8859-1 is used when the page directive is in header.jsp and UTF-8 is used when the page directive is in page1.jsp. For example, one same accented character are encoded these two ways: \u00c3\u00a9 -- displayed incorrectly. \u00e9 --> displayed correctly According to the help doc, Resin uses ISO-8859-1 as the default encoding, so I added <character-encoding>utf-8</character-encoding> in resin.xml (tried globally and in the web-app). It had no effect. |
||||
Steps To Reproduce: | |||||
Additional Information: |
Workaround: Add <%@page contentType="text/html; charset=UTF-8" pageEncoding="UTF-8" %> to each of the erroneous JSP pages |
||||
Relationships | |||||
Attached Files: |
Notes | |||||
|
|||||
|
|