: You're almost there. Drop the very first RewriteCond (as it's not required and won't match ever) and add a trailing / to your last RewriteRule since you're redirecting with them. RewriteEngine
You're almost there. Drop the very first RewriteCond (as it's not required and won't match ever) and add a trailing / to your last RewriteRule since you're redirecting with them.
RewriteEngine On
RewriteCond %{HTTP:Accept-Language} ^en [NC]
RewriteRule ^$ mysite.com/en/ [L,R=301]
RewriteCond %{HTTP:Accept-Language} ^de [NC]
RewriteRule ^$ mysite.com/de/ [L,R=301]
RewriteCond %{HTTP:Accept-Language} ^nl [NC]
RewriteRule ^$ mysite.com/nl/ [L,R=301]
RewriteCond %{HTTP:Accept-Language} ^fr [NC]
RewriteRule ^$ mysite.com/fr/ [L,R=301]
RewriteCond %{HTTP:Accept-Language} ^es [NC]
RewriteRule ^$ mysite.com/es/ [L,R=301]
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-l
RewriteRule ^(en|de|nl|fr|es)/?$ index.php?lang= [QSA,NC,L]
More posts by @Lee4591628
Terms of Use Create Support ticket Your support tickets Stock Market News! © vmapp.org2024 All Rights reserved.