httpd-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Zbigniew Szalbot" <zszal...@gmail.com>
Subject Re: [users@httpd] language-based redirection
Date Mon, 04 Feb 2008 17:23:35 GMT
Hello,

2008/2/4, Nick Kew <nick@webthing.com>:
> On Mon, 4 Feb 2008 11:30:59 -0500
> "Joshua Slive" <joshua@slive.ca> wrote:
>
> > On Feb 4, 2008 1:43 AM, Zbigniew Szalbot <zszalbot@gmail.com> wrote:
> >
> > > The thing is that in order to provide blogs in two languages I
> > > cannot install one blog and make it display in two languages. It
> > > needs to be two blogs. Hence, they need to be in two separate
> > > directories. But I am happy to do the langauge recognition in a
> > > common directory and then redirect to a specific blog. Thank you!
> >
> > If you want the full language negotiation done by apache (checking
> > priorities, etc), then your meta-refresh hack may indeed be the best
> > idea.
>
> Meta refresh is never, ever, acceptable.  It buggers up browsers.
>
> Looking up the thread, an altogether better solution would be
> to use mod_asis to generated external redirects from the
> content-negotiated indexes.
>
> You should still of course enable users to override that choice.
> For example a visitor may be fluent in both languages, or may be
> traveling, and using a hotel or library's browser configured with
> different preferences to their own.

Thanks Nick. I did have a loot at:
http://webauth.stanford.edu/manual/mod/mod_asis.html

Now, what I do not understand is what should the HTML file contain.

<html>
<head>
<title>Lame excuses'R'us</title>
</head>
<body>
<h1>Fred's exceptionally wonderful page has moved to
<a href="http://xyz.abc.com/foo/bar.html">Joe's</a> site.
</h1>
</body>
</html>

Only this? Or should the header contain this:

Status: 301 Now where did I leave that URL
Location: http://xyz.abc.com/foo/bar.html
Content-type: text/html

I do not really want to show people a page moved message as nothing
has moved. I just want to redirect to two different subdirectories
based on browser's language.

Thanks!

Zbigniew Szalbot

---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
   "   from the digest: users-digest-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org


Mime
View raw message