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

categories - Category no longer exists?

programmeradmin4浏览0评论

So my problem is I changed /services/ (which is a page but also a category) to /services-old/ and replaced it with a new /services/ page. But the system is not letting go of the old page so everything /services/ was redirecting to /services-old/ even though I set it the old page to draft. So I deleted the old page but now the URLs simply remove /services/ altogether, even though the page and category exist. So what should show as redirects to .

It's like there is a redirection in the database somewhere. We do have a redirection plugin, but I killed it and the redirection is still happening.

Any ideas?

So my problem is I changed /services/ (which is a page but also a category) to /services-old/ and replaced it with a new /services/ page. But the system is not letting go of the old page so everything /services/ was redirecting to /services-old/ even though I set it the old page to draft. So I deleted the old page but now the URLs simply remove /services/ altogether, even though the page and category exist. So what should show as https://www.domain/services/validation redirects to https://www.domain/validation.

It's like there is a redirection in the database somewhere. We do have a redirection plugin, but I killed it and the redirection is still happening.

Any ideas?

Share Improve this question asked Mar 5 at 18:22 Repo101Repo101 1 2
  • Make sure you're checking redirects in incognito/fresh browser, as 301's in particular are cached at the browser level. – TheDeadMedic Commented Mar 6 at 12:22
  • Maybe also rebuild permalinks by going to Settings -> Permalinks and resaving what you have there. – Tony Djukic Commented Mar 9 at 20:49
Add a comment  | 

1 Answer 1

Reset to default 1

You have a couple of problems here.

/services/ (which is a page but also a category)

Pages and Categories should have unique slugs that don't clash with each other. When you visit https://yourdomain/services/ WP needs to be able to parse the URL and know whether it should be displaying https://yourdomain?p=123 or https://yourdomain?cat=21.

As far as removing the page goes, WP won't release the rewrite on a Post or Page until it's been deleted and purged from the Trash, because if you reused the slug it wouldn't be able to restore the Page/Post with one click. A similar situation applies to Drafts: they already have a permalink assigned, and being able to reuse it for something else would break the Publish button.

发布评论

评论列表(0)

  1. 暂无评论