I would like a redirection for many pages (10 000).
For example, I need :
example.com/home-office-london/
to
example.com/office-london/
and
example.com/home-office-paris/
to
example.com/office-paris/
I want this with a 301 redirection by .htaccess
.
Can you help me please?
2
Answers
That's ok for me. Thanks a lot.
From your examples it would seem you are removing
home-
from the start of the URL-path. These URLs consist of a single path segment and end with a slash.You can do this using mod_rewrite (since I assume you are already using mod_rewrite) at the top of the root
.htaccess
file:Test first with a 302 (temporary) redirect to avoid potential caching issues.