08-20-04 12:47 PM
On Fri, 20 Aug 2004, Victor Engmark wrote:
> I have a web page built using files like index.php.en and
> index.php.no. The core of the problem is that language negotiation
> doesn't seems to work. When the client doesn't accept neither
> English nor Norwegian, the "406 Not Acceptable" page shows up. I
> thought I could avoid this by creating a symlink called index.php to
> index.php.en, but then clients which prefer Norwegian will never
> show index.php.no (I've tested on IE and FireFox). What am I doing
> wrong?
If your server is Apache 2.0, then read its documentation - this is
solved without additional work on your part (take away your symlink).
If your server is Apache 1.3 then there is a workaround suggested in
my tutorial http://ppewww.ph.gla.ac.uk/~flavell/www/lang-neg.html
Read especially the sub-heading "The Status 406 Language Dilemma", and
then the heading "Use of Apache MultiViews".
This works well with "html" (you need to call the symlink
index.html.html , instead of just index.html). I didn't try it with
php, but maybe you can try index.php.php or index.php.html or such?
Or change your href="whatever.php" into href="whatever" , and leave
Multiviews to supply the extension.
[ Post a follow-up to this message ]
|