WebSphere Portal Server - sun.io.MalformedInputException for extended characters in jsps

This is Interesting: Free IT Magazines  
Home > Archive > WebSphere Portal Server > June 2004 > sun.io.MalformedInputException for extended characters in jsps





You are viewing an archived Text-only version of the thread. To view this thread in it's original format and/or if you want to reply to this thread please [click here]

Author sun.io.MalformedInputException for extended characters in jsps
news.software.ibm.com

2004-06-02, 4:49 pm

Hi

I am getting the following exception from a struts portlet when it
encounters extended characters.


sun.io.MalformedInputException
at sun.io.ByteToCharUTF8.convert(ByteToCharUTF8.java(Compiled Code))
at java.io.InputStreamReader.convertInto(InputStreamReader.java:152)
at java.io.InputStreamReader.fill(InputStreamReader.java:201)
at java.io.InputStreamReader.read(InputStreamReader.java:264)
at java.io.Reader.read(Reader.java:116)

Problem occurs for static text or jsp, bean:message from properties file or
bean:write from value bean.


Have included following in JSPs
<%@ page contentType="text/html; charset=utf-8" %>

<% response.setContentType("text/html; charset=UTF-8"); %>

<meta HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=UTF-8">

struts-config.xml:
<controller processorClass="com.ibm.wps.portlets.struts.WpsRequestProcessor"
contentType="text/html; charset=utf-8" in

The portlet is deployed on WebSphere PortalServer 4.2 Extend, with WebSphere
4.05 AppServer.

Running the same struts application as a Web Applicaton in local test server
works as expected (WebSphere v4.0 Test Environment), WebSphere Application
Developer 5.1.

Has anyone seen this before, or have any ideas...

I have read on some other forums that for other app servers you can
precompile jsps passing encoding argument - is this possible with WSAD?
Doesn't seem to be an option, only able to set to Procompile in web.xml
extensions tab.

Regards

Michael


toskumar

2004-06-22, 6:00 pm

I had similar problem in JSP and i resolved it by including this tag &lt;@ page pageEncoding='ISO-8859-1'&gt; in jsp page or in controller struts config file.

Sponsored Links






Free braindumps | Software forum | Database administration forum

Copyright 2003 - 2008 webservertalk.com