Aller au contenu
Infogérance Linux Debian en France

Infogérance Linux Debian en France

Kogitae : Ingéniérie de l'hébergement Internet

  • Accueil
  • Parcours
  • Presse
  • Portfolio
  • Blog

Change the default Apache character set | Racker Hacker

  • Accueil » Blog » Change the default Apache character set | Racker Hacker
DansApache, Hebergement

Change the default Apache character set | Racker Hacker

Change the default Apache character set

By default, Red Hat Enterprise Linux 4 sets the default character set in Apache to UTF-8. Your specific web application may need for the character set to be set to a different value, and the change can be made fairly easily. Here’s an example where the character set is changed to ISO-8859-1:

First, adjust the AddDefaultCharset directive in /etc/httpd/conf/httpd.conf:

#AddDefaultCharset UTF-8

AddDefaultCharset ISO-8859-1

Then, reload Apache and check your headers:

# /etc/init.d/httpd reload

# curl -I localhost

HTTP/1.1 403 Forbidden

Date: Thu, 08 Nov 2007 22:18:14 GMT

Server: Apache/2.0.52 (Red Hat)

Accept-Ranges: bytes

Content-Length: 3985

Connection: close

Content-Type: text/html; charset=ISO-8859-1

viaChange the default Apache character set | Racker Hacker.

adddefaultcharset-iso-8859-1 apache apache-adddefaultcharset apache-charset apache-hed-hat-server-hack apache-redhat-utf8 changer-charset-apache changing-utf-8-to-iso-8859-1-in-the-httpd-conf-in-redhat-7-2 character-set-linux-red-hat character-set-sous-linux charset-apache charset-dfaut-linux-redhat default-charset-awstats hacker-apache2-0-52 hacker-un-blog-sous-appache-2-0 how-to-know-default-charset-linux latin 1 set-charset set-gmt1-apache utf8

Étiquettes

administrateur-systeme-freelance (9) amazon (3) apache (14) asterisk (9) auth (3) bash (6) blog-administrateur-systeme (14) blog-administration-systeme (4) collectd (5) cpu (3) debian (30) dovecot (4) duplicate (3) f (6) freelance-asterisk (3) google (3) infogerance-linux (5) infogérance (4) ipv6 (7) kernel (4) kogitae (30) kogitae-com (3) kogitae-fr (6) lamp-or-linux-or-developpement-web-and-apache-or-php-or-mysql-or-adobe-or-eclipse-or-zend-or-mozilla-or-firefox (17) lenny (4) lighttpd (5) limit (4) linux (26) mail (7) mdadm (6) mysql (14) openvz (9) optimiser (4) php (5) postfix (11) privvmpages-openvz (3) pxe (3) raid (3) SEO (5) ssh (8) ssl (3) test (3) voip (4) wordpress (6) www-kogitae-fr (7)