Opened 6 years ago
Last modified 4 years ago
#46257 new defect (bug)
Deleting a page can break the permalink of other pages if it had media uploaded to it
Reported by: | mallorydxw | Owned by: | |
---|---|---|---|
Milestone: | Awaiting Review | Priority: | normal |
Severity: | normal | Version: | 5.0.3 |
Component: | Permalinks | Keywords: | |
Focuses: | Cc: |
Description
Trashing and deleting a page can cause the permalink of another page to break the next time that page is edited. It is not obvious to the user that this will happen. It is also not obvious how to fix this, because when an image is not "Uploaded To" a particular page, it is not possible to edit the permalink.
- Start with vanilla WP installation using twentynineteen and no plugins
- Add New Page > Title: "Cat"
- Add Block > Image > Upload > Pick the image > Open
- Publish... > Publish
- Media > Click on the image that was just uploaded, see that it says "Uploaded To Cat"
- Edit more details > Edit (permalink) > Set to "dog" > OK > Update
- The permalink should now be
http://localhost/cat/dog/
- Add New Page > Title: "Dog" > Publish... > Publish
- See that "Page address" is
http://localhost/dog/
- Visit
/dog/
to confirm the page is displayed - Pages > Trash (Cat) > Trash (at the top of the page) > Empty Trash
- Pages > Dog > Make a change, such as adding text to the existing block > Update
- Document > Permalink > Notice that URL is now
dog-2
- Visit
/dog/
to see that instead of the page, the image is instead displayed
Note: See
TracTickets for help on using
tickets.