开发者

Setting the character encoding in Day CQ

开发者 https://www.devze.com 2023-04-08 08:37 出处:网络
I\'ve got some markup that I\'m adding to a page component in Day CQ that was UTF-8 encoded by the author. Initially I couldn\'t save it in CRXDE, b/c the editor was set to save in ISO-8859-1. I found

I've got some markup that I'm adding to a page component in Day CQ that was UTF-8 encoded by the author. Initially I couldn't save it in CRXDE, b/c the editor was set to save in ISO-8859-1. I found the sett开发者_开发问答ing to change this, but now when the page using this component is rendered to the browser, some of the characters appear to be using a different encoding. Is there a setting for the CQ web server, or servlet engine that I need to change? I'm running CQ 5.3 on Windows 7.

Edit: The HTTP Headers have Content-Type: text/html;charset=UTF-8 and there is a meta tag that specifies meta http-equiv="Content-type" content="text/html; charset=utf-8"


I believe the solution was to add pageEncoding="UTF-8" to all JSP's that are part of rendering this page. I also modified the web.xml file per this link: http://www.coderanch.com/t/87264/Tomcat/Character-Encoding-Tomcat, and restarted the server a number of times.

0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号