B
B
babavoz2022-02-08 13:23:42
htaccess
babavoz, 2022-02-08 13:23:42

How to make 301 redirect url htaccess?

Hello, I'm trying to make a redirect like:
RewriteCond %{QUERY_STRING} ^_route_=old$
RewriteRule ^(.*)$ https://site/new ? [R=301,L]

i.e. I need to redirect https://site/old to https://site/new
but for some reason nothing works, please tell me what could be the problem

Answer the question

In order to leave comments, you need to log in

1 answer(s)
D
dodo512, 2022-02-08
@dodo512

need to redirect https://site/old to https://site/new

RewriteRule ^old$ https://site/new? [R=301,L]
Put at the beginning of the file so that this rule is above the rules of OpenCart.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question