[wp-trac] [WordPress Trac] #15665: Page name won't work if the parent page has an attachment with the same name

WordPress Trac wp-trac at lists.automattic.com
Fri Dec 3 17:18:01 UTC 2010


#15665: Page name won't work if the parent page has an attachment with the same
name
--------------------------+-------------------------------------------------
 Reporter:  designsimply  |       Owner:                          
     Type:  defect (bug)  |      Status:  new                     
 Priority:  normal        |   Milestone:  Awaiting Review         
Component:  General       |     Version:  3.1                     
 Severity:  normal        |    Keywords:  has-patch, needs-testing
--------------------------+-------------------------------------------------
 It's possible to create a page name that has the same name as an
 attachment page with the same parent. If you do that, the attachment page
 takes precedent and it's not possible to display the page with the
 matching name.

 To reproduce:  [[BR]]
 1. Create a page, attach some images to it, save and publish [[BR]]
 2. Create a child page with the same name as one of images attached to the
 parent page [[BR]]
 ---> Result: a page name and an attachment page name that are the same and
 it's not possible to view the page at
 http://example.com/parent_page_name/page_name/

 Tested with r16708

 Making the attachment post type hierarchical fixes it this my tests. Is
 there any reason attachment post types should not be hierarchical?

-- 
Ticket URL: <http://core.trac.wordpress.org/ticket/15665>
WordPress Trac <http://core.trac.wordpress.org/>
WordPress blogging software


More information about the wp-trac mailing list