w3hello.com logo
Home PHP C# C++ Android Java Javascript Python IOS SQL HTML videos Categories
Exclude a substring in htaccess RewriteRule redirect

Try replacing all of that with just this:

RewriteRule ^eng/(.*) en/$1 [R,L,NE,DPI]

If it works, you can change the R to R=301


To test this, you must use a new browser. This is because browsers cache 301 redirects, so your current browser will keep redirecting to the old (wrong page) without even talking to your server and hitting the new .htaccess—unless you clear the browser cache.

© Copyright 2018 w3hello.com Publishing Limited. All rights reserved.