• Post Reply Bookmark Topic Watch Topic
  • New Topic

display the euro symbol "�"  RSS feed

 
heiner weilandt
Ranch Hand
Posts: 46
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
hi,
i want to display the currency euro in a browser (JSP with a bean) and i got the problem that the "�" is displayed as a "?". by using System.out.println() the "�" is correctly displayed in the command. in html, i use "iso-8859-15".
---------------------------
Locale locale = new Locale ("fr","FR","EURO");
NumberFormat format = NumberFormat.getCurrencyInstance(locale);
return format.format(1234.56);
---------------------------
i use tomcat 4 and websphere 4 with jdk 1.3.1
thanks for help
heiner
[ March 06, 2003: Message edited by: heiner weilandt ]
 
Zabe Agha
Greenhorn
Posts: 19
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
OK, I'm having trouble posting the answer since it's being interpreted by the HTML. You might want to try ("The equivelant of"):
ampresand euro;
(but without the space in between the ampresand and the euro
[ March 06, 2003: Message edited by: Aurangzeb Agha ]
 
heiner weilandt
Ranch Hand
Posts: 46
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
i dont't want to display the euro-symbol by hand. i want to use the upper code to convert automaticly the currency by the Locale.
i think it is a problem by convert from html to internal java codepage. i use the jsp(html) and the java System.out.println() display this as "?". then i returned this "?" symbol by a getter-method to the jsp(html) and it's a "�" ???

i believe the Locale have the same problem to convert from java into this html-code, in this case iso-8859-15.
what is the internal java codepage ?
what can i do to convert between this two sides ?
or i'm wrong ?
 
Zabe Agha
Greenhorn
Posts: 19
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
See the above answer--I've edited it.
 
heiner weilandt
Ranch Hand
Posts: 46
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
thanx for your answer, but it's my opinion to use the Locale without scanning any string to convert by hand.
i believe the right questions is to convert the java-internal-codepage to iso-8859-15.
[ March 06, 2003: Message edited by: heiner weilandt ]
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!