Win a copy of Cross-Platform Desktop Applications: Using Node, Electron, and NW.js this week in the JavaScript forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

How to display euro sign into a xhtml page  RSS feed

 
Radu Mircea
Ranch Hand
Posts: 45
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,

I am trying to display only the euro sign into a xhtml page, it is really a trouble for me because until now i display it using a numeric converter but now only the euro sign is needed something like " prices are displayed in E" where E is the euro sign, no numeric values are required.

Please if you have an idea give me a hand.

Regards,
Radu
 
Ulf Dittmer
Rancher
Posts: 42972
73
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Wouldn't "€" work?
 
Radu Mircea
Ranch Hand
Posts: 45
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,

Thanks for posting.
The euro sign should be displayed from content of an xhtml page something like:

<h: outputLabel value="these prices are in "codeForEuroSign" for="myId">

Best regards,
Radu
 
Tim Holloway
Bartender
Posts: 18662
71
Android Eclipse IDE Linux
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
If you're using an XML JSF format, the HTML entity names can't be used - at least without more work than it's usually worth.

Fortunately, the raw entity code can be. It's &#8364; - thus: € Please don't forget the trailing semicolon (;). Not all browsers will render properly if you omit it.
 
Radu Mircea
Ranch Hand
Posts: 45
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi !

Thanks a lot for posting, it is ok the sign was displayed.

I also tried to load the sign from application properties ,file something like but in that case
only numeric code was displayed, is there a chance to load the sign from application properties files ?


Best regards,
Radu
 
Tim Holloway
Bartender
Posts: 18662
71
Android Eclipse IDE Linux
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Add the escape="false" attribute to your outputLabel/outputText element and you should be OK. It keeps HTML from being interpreted as displayable text.
 
Radu Mircea
Ranch Hand
Posts: 45
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi again,

I try it and worked, thanks a lot for helping !

Best regards,
Radu
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!