Opened 7 years ago
Closed 6 years ago
#3033 closed defect (bug) (fixed)
Identical Permalinks for Different Attachments
| Reported by: |
|
Owned by: |
|
|---|---|---|---|
| Priority: | normal | Milestone: | 2.1 |
| Component: | Administration | Version: | 2.1 |
| Severity: | normal | Keywords: | post_name bg|has-patch attachment permalink |
| Cc: |
Description
If you upload 2 different attachments in one post, give them the same title, and send them to the editor "linked to page," then both will end up with the same permalink for their "pages."
It happens because wp_insert_attachment() doesn't check to see if the post_name already exists.
My patch increments the post_name similarly to the way in which a regular post's post_name increments when it has a duplicate.
Attachments (1)
Change History (2)
Note: See
TracTickets for help on using
tickets.

(In [4561]) Make sure multiple attachments for the same post have unique permalinks. Props filosofo. fixes #3033