I’m having a pretty strange problem with server-side includes in conjunction with content negotiation. Specifically, a whole lotta garbage characters appear whenever I try to include a file affected by content-negotiation.
It’s worth mentioning that this issue only seems to happen on Dreamhost. If I try using my files with a locally installed Apache Server or my office server, everything functions exactly as I’d expect.
Here’s the simplest way to see my problem.
I have three file: .htaccess, index.shtml.en, and menu.shtml.en
The .htaccess file simply contains information about language-based content negotiation:
AddLanguage en .en
The index.shtml.en file simply contains some text, then includes the menu:
Note that I’m including menu.shtml and not menu.shtml.en; this is intentional, and should work. (And, indeed does work on my own Apache server—just not Dreamhost.)
The menu.shtml.en simply contains some text:
Now, the problem: when I access the index page on my Dreamhost server, the menu text appears followed by a string of garbage characters. The actual index page text doesn’t appear at all. You can see it for yourself here.
Has anyone experienced this before? What should I do?