开发者

Redirecting a dynamic page to a new dynamic page

My site has the following url structure:

/shoe/view/3
/shoe/view/5
/shoe/view/86
/shoe/view/124

I want to 301 redirect everything using htaccess to a new structure like so:

/开发者_如何学运维item/3
/item/5
/item/86
/item/124


This should do the job:

RedirectMatch 301 \/shoe\/view\/(.*)$ http://www.example.com/item/$1


What about something like this :

RewriteEngine on
RewriteRule ^shoe/view/(.*)$ /item/$1 [R=301]
0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜