Make WordPress Core

Changes between Initial Version and Version 15 of Ticket #12821


Ignore:
Timestamp:
09/10/2010 04:07:33 AM (14 years ago)
Author:
nacin
Comment:

Legend:

Unmodified
Added
Removed
Modified
  • Ticket #12821

    • Property Status changed from new to reopened
    • Property Cc kevinB added
    • Property Summary changed from Allow get_pages() to query non-heirarchical post types? to Merge get_posts() and get_pages()
    • Property Milestone changed from Unassigned to 3.1
    • Property Keywords needs-patch added
  • Ticket #12821 – Description

    initial v15  
    1 It seems "hierarchical" is an optional argument and yet get_pages() checks for non-hierarchical post types and if so exits.  Is there a reason for get_pages() not to support non-heirachical post types?  Seem like it might be a legacy concern prior to custom post types?
     1get_pages() should wrap get_posts() the same way get_page() wraps get_post(). Arguments of different names need to be retained for back compat.
    22
    3 FYI, I changed my custom post type where I ran into this to be hierarchical just to test it and it worked fine but that custom post type really should be hierarchical.
     3Reasoning for this includes #14823. Querying a nonhierarchical post type should still be allowed with child_of for example, to allow for cross-type relationships.