WordPress.org

Make WordPress Core

Opened 6 years ago

Closed 6 years ago

Last modified 6 years ago

#6068 closed defect (bug) (fixed)

permalink shown on edit page page incorrect for sub-pages

Reported by: DD32 Owned by:
Milestone: 2.5 Priority: normal
Severity: normal Version: 2.5
Component: Administration Keywords:
Focuses: Cc:

Description

The permalink shown on the "edit page" page does not show correctly for sub-pages.

Eg, I've got a page, with the parent "WordPress Plugins"(slug: wordpress-plugins), the permalink shown is:

Permalink: http://dd32.id.au/remove-max-width/ Edit

While in reality, it exists at:

http://dd32.id.au/wordpress-plugins/remove-max-width/

(Note that the "View this page" link does point to the right location.

Change History (5)

comment:1 ryan6 years ago

  • Resolution set to fixed
  • Status changed from new to closed

(In [7133]) Show page hierarchy when editing page slugs. fixes #6068

comment:2 ryan6 years ago

str_replace()ing the post_name in the page uri may need to change so that parents that have post_name in their text aren't stomped. Only the deepest child should be replaced.

comment:3 ryan6 years ago

  • Resolution fixed deleted
  • Status changed from closed to reopened

comment:4 westi6 years ago

  • Resolution set to fixed
  • Status changed from reopened to closed

(In [7320]) Only replace the last segment of the uri when generating the sample permalink. Fixes #6068.

comment:5 westi6 years ago

  • Keywords needs-patch removed

The new code works for me in testing a hierarchy with repeated page names.

Note: See TracTickets for help on using tickets.