A
A
artimore2018-03-25 17:24:45
htaccess
artimore, 2018-03-25 17:24:45

How to make a mass redirect (rule) in htaccess?

There are pages with such old URLs.
site.com/shop/catalog/product/name_product It is
necessary to remove "shop" from the URL so that for all products the structure becomes the following
site.com/catalog/product/name_product
How to redirect a 301 page redirect?
Thank you.

Answer the question

In order to leave comments, you need to log in

1 answer(s)
E
ElijahTr, 2018-03-25
@ElijahTr

RewriteRule ^/?shop/?(.*)$ /$1 [R=301,L]

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question