最新消息:雨落星辰是一个专注网站SEO优化、网站SEO诊断、搜索引擎研究、网络营销推广、网站策划运营及站长类的自媒体原创博客

url rewriting - How to redirect to correct pages after permalink structure change

programmeradmin1浏览0评论

I am changing my permalink structure from /%year%/%monthnum%/%postname%/ to /%category%/%postname%/.
Is it possible to redirect old links using old permalink structure to the new link? Possibly via the postname?

I am changing my permalink structure from /%year%/%monthnum%/%postname%/ to /%category%/%postname%/.
Is it possible to redirect old links using old permalink structure to the new link? Possibly via the postname?

Share Improve this question asked Oct 12, 2012 at 2:27 ImranImran 2235 silver badges12 bronze badges
Add a comment  | 

2 Answers 2

Reset to default 1

Wordpress should handle all redirections correctly, without you needing to worry about them. For example, if your old post was http://example/2012/10/11/i-like-stackexchange any links should auto-magically be redirected to http://example/favorite-things/i-like-stackexchange. I just tested it on a site with Wordpress 3.4 installed, and it worked just fine. Wordpress can read your mind.

When you change your permalinks WordPress doesn't always catch all the URLs that were changed. Luckily, there is a code solution from yoast: https://yoast/research/permalink-helper.php

Enter the old structure, new structure, and it outputs redirect code.

Works every time I used it.

发布评论

评论列表(0)

  1. 暂无评论