Niki Kovacs
2009-Sep-19 08:05 UTC
[CentOS] Apache configuration: minor problem with special characters
Hi, I'm currently fiddling with protecting sections of a website with .htaccess. Here's an example: <Files .htaccess> order allow,deny deny from all </Files> AuthUserFile /etc/httpd/htpasswd AuthName "L'acc?s ? ce site est restreint." AuthType Basic require valid-user The configuration works OK (after having created a valid user), but unfortunately, the message in the infobox that pops up on the site displays the french characters ? and ? incorrectly. Any idea how I could get this right? I'm more or less starting out from Apache's default httpd.conf. Cheers, Niki
Niki Kovacs
2009-Sep-19 08:23 UTC
[CentOS] Apache configuration: minor problem with special characters
Niki Kovacs a ?crit :> > The configuration works OK (after having created a valid user), but > unfortunately, the message in the infobox that pops up on the site > displays the french characters ? and ? incorrectly. > > Any idea how I could get this right? I'm more or less starting out from > Apache's default httpd.conf. >I found the following workaround. Once my .htaccess file is edited, convert it from UTF-8 to ISO-8859-1 with recode: # recode utf8..latin1 .htaccess Now the french message displays correctly. Any other maybe more orthodox suggestions? Niki
nate
2009-Sep-19 12:21 UTC
[CentOS] Apache configuration: minor problem with special characters
Niki Kovacs wrote:> Any idea how I could get this right? I'm more or less starting out from > Apache's default httpd.conf.I don't know how to fix your issue but I would run tcpdump and see what apache is actually sending, to rule out the browser being the problem rather than the server. nate