This week's book giveaway is in the Servlets forum.
We're giving away four copies of Murach's Java Servlets and JSP and have Joel Murach on-line!
See this thread for details.
The moose likes I/O and Streams and the fly likes Encoding - UTF-8 cannot display Extended ASCII Character ? Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Murach's Java Servlets and JSP this week in the Servlets forum!
JavaRanch » Java Forums » Java » I/O and Streams
Bookmark "Encoding - UTF-8 cannot display Extended ASCII Character ?" Watch "Encoding - UTF-8 cannot display Extended ASCII Character ?" New topic
Author

Encoding - UTF-8 cannot display Extended ASCII Character ?

Nicky Eng
Ranch Hand

Joined: Mar 26, 2005
Posts: 378
I have 2 web application and found one funny case which is in Admin the character display fine but it displays blank/question_mark for the character in User Web.

1 - Admin
2 - User Web

In Admin application, in web.xml encoding is iso-8859-1. and all the JSPs i put this tag:



In UserWeb app, in web.xml encoding is utf-8 and all the JSPs i put this tag:



So the case is, I have this character in DB --> ' (which is chr(146) - extended ascii character)
In admin it retrieve from DB and display the character correctly as in --> '
but it doesn't display correctly in UserWeb.

DB character set is US7ASCII

--------------------
Is above encoding part is the cause of the issue ?
If so, why UTF-8 character encoding cannot somehow accept extended ascii character like chr(146) ?

Anyone got idea ?
I've been stuck for the whole day ...



From NickyEng
Diploma in Computer Studies
SCJP 1.4
SCWCD 1.4
Formula 1 app by Maxis (Playbook)
Stephan van Hulst
Bartender

Joined: Sep 20, 2010
Posts: 3573
    
  14

Are you using the same fonts in both applications to display the character?
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Encoding - UTF-8 cannot display Extended ASCII Character ?
 
Similar Threads
Spring MVC UTF-8 encoding problem
ISO-8859-2 and Struts
Problem while storing Japanese characters in Oracle 9i
Forwarding Response from Servlet to JSP
A problem with requested parameters