growl message is not displayed when using special characters

UI Components for JSF
Post Reply
ttruong
Posts: 109
Joined: 01 Mar 2010, 12:50

14 Jun 2010, 11:22

In my resource bundle I have:
COULD_NOT_PLAN_ORDERS = Some or all of the orders could not be planned:\r\n{0}

But the growl message is not displayed. Only when I remove the special characters:

COULD_NOT_PLAN_ORDERS = Some or all of the orders could not be planned: {0}!

Seems like a bug.

HTH Tai

cagatay.civici
Prime
Posts: 18616
Joined: 05 Jan 2009, 00:21
Location: Cybertron
Contact:

14 Jun 2010, 14:03

Do you get a javascript error, maybe you can try escaping your message. Because growl message needs to be a valid javascript string. We escape quotes and double quotes automatically when rendering.

ttruong
Posts: 109
Joined: 01 Mar 2010, 12:50

14 Jun 2010, 14:24

No I am not getting a java script error. How do I escape my characters? My intention is to display the message into two lines.
Besides: it is the Resource Bundle Editor (eclipse plugin) creating this special character ("\r\n" for new line). In case I have to escape my translation files manually that would mean that I cannot use the plugin. I am not sure whether this is a good idea. Isn't there a better solution?

Post Reply

Return to “PrimeFaces”

  • Information
  • Who is online

    Users browsing this forum: No registered users and 34 guests