So,
Say I have my shopping cart at foo.com/a
I want to redirect shoppers to foo.com/b
At foo.com my .htaccess
contains
RedirectMatch 302 ^/(index\.html)?$ foo.com/b
But people still land on foo.com/a (if they type it/have it bookmarked) It doesn't redirect. Only redirects if they land on foo.com
I'm sure it's a trivial problem. Can anyone help?
Talk to you all later.
Try using:
Just place this in a
.htaccess
file in the directory that you want to redirect.If you want to change the HTTP status code (redirect type) then just change the number.
Here is a link that talks more about it for reference.
https://help.dreamhost.com/hc/en-us/articles/215747748-How-can-I-redirect-and-rewrite-my-URLs-with-an-htaccess-file-
I fixed it.
Redirect permanent foo.com/b
In the foo.com/a .htacccess file did the trick.