Redirect rule Apache multiple Custom post type to posts
I read the related questions above but no answers...so here is my problem :
I recently created several custom post types . They are 13 of them located located in /news/ folder. For some personal reasons, yesterday I decided not to use the Custom post type anymore and rather re-write all of them as a "usual post" in my WP blog. So the 13 Custom PT are now duplicated. I could have delete them but they are already indexed by Google and their URL's are already around on the web, so I want to maintain them for a while to be sure that I do not loose any traffic of course.
开发者_运维百科The problem is that this morning, Google web master tool did not like all these duplicated contents at all.
I need to redirect all the 13 URL's to the new posts created. How can I redirect 13 URL's to 13 new URL's ? Is this rule enough ? Should I also mention not to follow the Custom Type URL ?
Here is the construction of the URL's: CUSTOM POST TYPES : www.mysite.com/myblog/news/custom-post-type-title/
URL OF THE NEW DUPLICATED ARTICLE : www.mysite.com/myblog/post-type-title
Thank you in advance for your help, Cheers.
To tell Google about duplicates, use code 301 when redirecting with RewriteRule (add [R=301] at the end of it) to denote "Permanently moved" on all URLs except for the currently valid one.
精彩评论