Forums

renamed then deleted page, now cant stop links automagically redirecting! (5 posts)

  1. jubilantjeremy
    Member
    Posted 4 months ago #

    Hello,

    I am having some problems with a page which I renamed then subsequently deleted. I attempt to make a new page with the same name, but existing hard-coded links in my theme are being redirected to the renamed page (which is also now trashed). I can't get my new page to appear under the old url.

    My permalink structure in WP is /%pagename%/.

    To give an example, say I have a page called doughnuts. I then decide that I am going to completely redo this page so i create a page called doughnutstest.
    Now I am happy with the way doughnutstest looks so I go to my pages, and rename doughtnuts to doughnutsold, and then rename doughnutstest to doughnuts.

    In my theme I have a hard-coded link to /doughnuts but whenever I click it, wordpress redirects me to /doughnutsold, which does not exist.

    This is a frustrating problem - thanks for any help!

    Cheers
    J

  2. SwansonPhotos
    Member
    Posted 4 months ago #

    The title is not the same as the slug. It's the slug that is used on rewrite.

    Is there a page in the 'trash' with that slug?

  3. jubilantjeremy
    Member
    Posted 4 months ago #

    Thanks for the reply,

    The trashed page has its slug set as 'doughtnutsold'.

    The slug on the new page is set to 'doughnuts'.

    I just double-checked all that. Do you think permanently deleting the old page will help?

    Additionally, all the child pages of the 'doughnuts' page have all had their URLs automatically changed to /doughnutsold/subpage.
    Do you think the presence of child pages could be causing an issue (wordpress doesn't want to break links?)

  4. SwansonPhotos
    Member
    Posted 4 months ago #

    I would think that you would need to first edit all child pages and change the parent page associated with them and then delete the parent page...next, create a new parent page, then again edit the child pages to point to new parent page.

  5. jubilantjeremy
    Member
    Posted 4 months ago #

    Yes, very laborious, but those steps (or something similar) worked. It was a bit flaky and I had to do it a couple of times. Thanks for your help!

Reply

You must log in to post.

About this Topic