Hi all,
I'm including a UTF-8 JSP in my Portlet's dowView() as in the code snippet below.
The JSP contains some non-latin characters (german umlauts, in my case). These characters
are not displayed correctly in the browser, however.
If I simply user response.getWriter().println() to print the same characters, they are
displayed correctly.
Can you configure the dispatcher somehow to set the encoding to UTF8? Any ideas why
included JSPs are not displayed UTF8-conform?
| public void doView(RenderRequest request, RenderResponse response) throws
PortletException, IOException, UnavailableException {
| response.setContentType("text/html");
| String contentUrl = getContentUrl(request, response);
| PortletContext context = getPortletContext();
| PortletRequestDispatcher dispatcher = context.getRequestDispatcher(contentUrl);
| try {
| dispatcher.include(request, response);
| } catch (Exception e) {
| response.getWriter().println("Cannot display content!");
| }
| }
|
View the original post :
http://www.jboss.org/index.html?module=bb&op=viewtopic&p=4252242#...
Reply to the post :
http://www.jboss.org/index.html?module=bb&op=posting&mode=reply&a...