UTF-8 Encoding Error


If you are using J2EE level 1.2, then to be able to run on WAS Version 3.5 or Version 4.0, you need to set the UTF-8 encoding (that WebFacing uses to provide support for international character sets) in the application server.

Note  

You need to enable UTF-8 encoding even if you are using WAS Version 5.0 but your project uses J2EE level 1.2.

If you have not set this environment variable in the application server, you will receive an error when data is sent back to the server from the first WebFaced page, as shown in Figure 18.12.

click to expand
Figure 18.12: Error because UTF-8 setup is missing in the Version 4.0 application server

As you can see, the message clearly indicates that the problem is caused by the browser's failure to send a UTF-8 encoded data stream.

For J2EE level 1.2 projects,

  • The application server has to be set up to properly handle UTF-8 encoding. For every application server you use, you need to do the setup task once. If you use the WAS test environment on your workstation first and set up UTF-8 there, and then you move to your iSeries WAS production server, you will have to repeat the UTF-8 setup for this server as well.

  • Follow the instructions in the WebFacing Help, under: Tasks Configuring UTF-8 support in WebSphere Application Server. You have to do this only once per application server that runs the WebFaced applications.

Note  

You do not need to configure UTF-8 for WAS Version 5.0 when using J2EE level 1.3. It is set up automatically.




Understanding the IBM WebFacing Tool. A Guided Tour
Understanding the IBM WebFacing Tool: A Guided Tour (IBM Illustrated Guide series)
ISBN: 1931182094
EAN: 2147483647
Year: 2003
Pages: 153

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net