Blogging Roller
Dave Johnson on open web technologies, social software and Java
Dave Johnson on open web technologies, social software and Java
Iñtërnâtiônàlizætiøn. Making Sam Ruby's suggested I18N test work in Roller required a code change and a configuration file change. First, the code change: I added the following line to force incoming form data to be parsed as UTF-8.
request.setCharacterEncoding("UTF-8");
The config change: I updated my velocity.properties file to support UTF-8:
input.encoding=UTF-8 output.encoding=UTF-8 default.contentType=text/html; charset=utf-8
Unfortunately, this breaks comments as you will see if you try to leave a comment. I'm working on this now.
Update: Roller followed a linkback to Simon Brown's Iñtërnâtiônàlizætiøn post, and lookee there, linkbacks need work too.
Another update: I'm tracking this in JIRA as bug ROL-341. By the way, it appears that JIRA handles iñtërnâtiônàlizætiøn flawlessly.
Yet another update: Thanks to a suggestion from David Czarnecki, who literally wrote the book on Java Internationalization, comments are working on posts with I18N titles. I had to add URIEncoding="UTF-8" in the Tomcat Connector configured in server.xml:
<!-- Define a Coyote/JK2 AJP 1.3 Connector on port 10039 -->
<Connector port="10039"
enableLookups="false" redirectPort="10033" debug="0"
protocol="AJP/1.3" URIEncoding="UTF-8" />
Tags: Roller