配置Apache和Tomcat使用UTF-8编码
2014-05-29 14:47
393 查看
以下技术应用于最优质的水果的鲜果篮
1, Goto your apache folder i.e. /etc/httpd/conf and add AddDefaultCharset utf-8 in httpd.conf file. Note: First check that it is exist or not. If exist you may update it with this line. You can add this line at bottom also.
2,Goto your tomcat folder i.e. $CATALINA_HOME/conf/server.xml, change releated setting for following 2 component.
<Connector port="8080" maxHttpHeaderSize="8192"
maxThreads="150" minSpareThreads="25" maxSpareThreads="75"
enableLookups="false" redirectPort="8443" acceptCount="100"
connectionTimeout="20000" disableUploadTimeout="true"
compression="on"
compressionMinSize="128"
noCompressionUserAgents="gozilla, traviata"
compressableMimeType="text/html,text/xml,text/plain,text/css,text/ javascript,application/x-javascript,application/javascript"
URIEncoding="UTF-8"
/>
...
...
<Connector port="8009" protocol="AJP/1.3" redirectPort="8443" URIEncoding="UTF-8"/>
1, Goto your apache folder i.e. /etc/httpd/conf and add AddDefaultCharset utf-8 in httpd.conf file. Note: First check that it is exist or not. If exist you may update it with this line. You can add this line at bottom also.
2,Goto your tomcat folder i.e. $CATALINA_HOME/conf/server.xml, change releated setting for following 2 component.
<Connector port="8080" maxHttpHeaderSize="8192"
maxThreads="150" minSpareThreads="25" maxSpareThreads="75"
enableLookups="false" redirectPort="8443" acceptCount="100"
connectionTimeout="20000" disableUploadTimeout="true"
compression="on"
compressionMinSize="128"
noCompressionUserAgents="gozilla, traviata"
compressableMimeType="text/html,text/xml,text/plain,text/css,text/ javascript,application/x-javascript,application/javascript"
URIEncoding="UTF-8"
/>
...
...
<Connector port="8009" protocol="AJP/1.3" redirectPort="8443" URIEncoding="UTF-8"/>
相关文章推荐
- Apache+Tomcat中支持“UTF-8”编码的中文地址(转)
- Apache mod_jk方式使用ajp13均衡集群整合Tomcat后的ssl配置
- 使用apache配置tomcat应用整合php论坛-discuz
- Spring/Tomcat Rest开发 配置UTF-8编码
- apache-tomcat-7.0.33 在win7 上配置使用
- Apache Tomcat UTF-8编码漏洞[转载至邪恶八进制]
- Apache+Tomcat中支持“UTF-8”编码的中文地址
- 使用Apache配置Tomcat应用整合PHP论坛-Discuz
- 修改配置文件使Netbeans默认使用UTF-8编码
- Tomcat7.0/8.0 详细安装配置图解,以及UTF-8编码配置
- 关于web开发使用utf-8编码所需的配置
- 在Lunix下配置使用Jmx监控apache-tomcat性能
- Apache+tomcat配置Openssl 之指定客户端目录使用Https
- 使用Apache配置Tomcat应用整合PHP论坛-Discuz
- Apache的安装和使用、二级域名的配置和使用和Apache+tomcat整合
- JAVA ,SSH中文及其乱码问题的解决 6大配置点 使用UTF-8编码
- Apache Tomcat UTF-8编码漏洞
- Apache 项目 之 commons-configuration-1.10.jar 使用 properties配置文件时的编码设置
- Apache Tomcat UTF-8编码漏洞
- 使用apache和nginx代理实现tomcat负载均衡及集群配置详解