Thanks Natty_D,
Hmmm, ok well it ain't workin 🙁
It works with Google.com but not with my page.
This is the script I'm using:
<?php
if(strstr($HTTP_ACCEPT_LANGUAGE,"en")) {
Header("Location: [url]http://www.mysite.com/uk/[/url]");
}
elseif(strstr($HTTP_ACCEPT_LANGUAGE,"fr")) {
Header("Location: [url]http://www.mysite.com/fr/[/url]");
}
elseif(strstr($HTTP_ACCEPT_LANGUAGE,"de")) {
Header("Location: [url]http://www.mysite.com/de/[/url]");
}
elseif(strstr($HTTP_ACCEPT_LANGUAGE,"it")) {
Header("Location: [url]http://www.mysite.com/it/[/url]");
}
elseif(strstr($HTTP_ACCEPT_LANGUAGE,"es")) {
Header("Location: [url]http://www.mysite.com/es/[/url]");
}
?>
The rest of the page is the html page where the user can choose which language he wants to visit. When I visit www.mysite.com it automatically directs me to www.mysite.com/uk/ so I figured it was workin ok.
Is there a better way of doing it?
Thanks,
Geoffo