Darn! I finally got over my problem... so let's get back to the very beginning...
I use apache 2.2.4. I've been using it without a problem for a long time. My needs for apache are very basic: I just need tons of directory listings (indexes) with the ability to follow symbolic links, and ~10 aliases. The files in the directory listings are on my local computer and they usually have "weird" encodings, so I needed to let apache know I need it to use UTF-8 as default charset/encoding. Simple to achieve... or so it seemed: I used to run apache installed via aptitude under /etc/apache2.
In /etc/apache2/apache2.conf there was a line:
And furthermore, of course,
All was fine until a while ago, when after the last apache2 package update, I realized the AddDefaultCharset directive didn't take effect anymore – no matter what encoding I would have tried to use instead of UTF-8.
First thing I did was go check with the apache documentation... and God saw that it was right! No, wait...
I was playing according to the manual, but somehow things didn't work as expected. I even tried adding the AddDefaultCharset line to /etc/apache2/apache2.conf directly, but to no avail.
Then I looked for an answer in the apache httpd bugs section, on mailing lists, forums... still no result.
Finally, somehow I found the answer (after an hour of frustrated googling)... actually it's not an answer as in: an explanation for why the AddDefaultCharset directive doesn't take effect anymore (this is why I'm labeling this post with "bugs" too), but it's at least a workaround for my problem at hand: my /etc/apache2/apache2.conf needs to have the following line:
At least now "it works"... I have all directory listings displayed in the UTF-8 encoding, such that all non-Latin content on my server is displayed correctly.
Note #1: Somehow, trying the good ol' AddDefaultCharset directive in apache 1.3 under FreeBSD yields the expected results.
Note #2: Somehow, trying the good ol' AddDefaultCharset directive in apache 2.2.8 (the latest release as of now), compiled from source, still doesn't work.