Rewrite old subfolder url

I moved the subdirectory of my site to root. "http://anumuhammad.net/home" at "http://anumuhammad.net/"

This site has a lot of reverse urls, and I need the whole old url redirected to the new url:

http: // anumuhammad. net / home / article / 212-2015-07-04-14-14-20-20 at http: // anumuhammad. net / article / 212-2015-07-04-14-14-20

http: // anumuhammad. net / home / article / to http: // anumuhammad. network / articles / http://anumuhammad.net/home/books/ at http://anumuhammad.net/books/

"home" should be removed when the visitor came from the old backlink. I searched a lot, but could not find a solution that would help me.

This is an addon on the Apache server.

Any help would be greatly appreciated.

thank

Julash

+4
source share
1 answer

Try:

 RedirectMatch ^/home/(.*)$ http://anumuhammad.net/$1
+2
source

All Articles