views:

296

answers:

3

How do I make sure the correct encoding (UTF-8) is used by Grails?

+1  A: 

Easier than I thought - simply make sure your editor is set to UTF-8 encoding.

Epaga
A: 

Maybe you shouldn't use UTF-8. Maybe you should try one of the 8859 ISO charsets:http://www.global-translation-services.com/iso8859.html#ISO-8859-1

Regards,Victor

VP
A: 

I've found that sometimes setting the file type to UTF-8 isn't enough. Sometimes you need to tell the AppServer.

response.setContentType("text/html; charset=UTF-8");
request.setCharacterEncoding("UTF-8");