Setting encoding in Grails controller's render method
- by Philippe
Hello,
I'm trying to build an RSS feed using Grails and Rome.
In my controller's rss action, my last command is :
render(text: getFeed("rss_2.0"), contentType:"application/rss+xml", encoding:"ISO-8859-1 ")
However, when I navigate to my feed's URL, the header is :
<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:dc="http://purl.org/dc/elements/1.1/" version="2.0">
...
Does anyone have a clue about WHY the encoding is UTF-8 when I set it to ISO-8859-1 in the render method ???
Thanks for your help !