Message: 4 Date: Tue, 9 Oct 2007 19:10:03 +0100 From: Chris G cl@isbd.net Subject: Re: [ALUG] Why does Firefox always use UTF-8 for this page? To: main@lists.alug.org.uk Message-ID: 20071009181003.GB59524@newred Content-Type: text/plain; charset=us-ascii
On Tue, Oct 09, 2007 at 06:40:47PM +0100, Chris G wrote:
...
However I'd really prefer to keep the default Charset as UTF-8 and change it to ISO-8859-1 for just the /home/chris/webdev/info hierarchy.
But how do I do it? Adding a .htaccess file with "AddCharset ISO-8859-1 .rst .txtl" to the directory /home/chris/webdev/info doesn't seem to do anything, but that doesn't surprise me really because I don't think my browser ever sees that .rst file. I also tried:-
<Directory /var/www/cgi-bin/pyblosxom.cgi> AddCharset ISO-8859-1 .rst .txtl AddDefaultCharset ISO-8859-1 </Directory>
I don't really understand the correspondence between your filesystem location and your URL-space one. Which are you trying to specify here? <Directory> is for filesystem locations, otherwise you want <Location>.
As has been said, if it's a request to a CGI script you can set the headers in the script. You should probably do it that way if possible, because I'm sure headers set by CGI trump Apache's default Charset and I suspect also the specific sets. You may find that the script already sets a charset (CGI scripts are required to provide a Content-type: header, I think).
Matthew