Make WordPress Core

Opened 15 years ago

Closed 14 years ago

#14675 closed enhancement (wontfix)

Enhancement: Better Post Type Handling for Permalinks and Queries

Reported by: johnpbloch's profile johnpbloch Owned by:
Milestone: Priority: normal
Severity: normal Version:
Component: Permalinks Keywords:
Focuses: Cc:

Description

This is an enhancement to add better handling of post type in permalinks and WP_Query. This will fix a few deficiencies in WordPress' handling of these items.

The first deficiency this addresses is that WordPress doesn't automatically handle multi-post queries for custom post types. For example, with a post type 'products', the permastruct is 'products/%products%'. If someone were to go to http://example.com/products/ they would find a 404 error, not a list of products. This enhancement adds a %post_type% rewrite tag to WP_Query that gets added to all custom post types when they're registered.

Second, this adds permalink support for all the normal rewrite tags for all post types.

Attachments (2)

patch.patch (7.0 KB) - added by johnpbloch 15 years ago.
14675.patch (7.1 KB) - added by johnpbloch 15 years ago.
Refreshed Patch

Download all attachments as: .zip

Change History (6)

@johnpbloch
15 years ago

#1 @johnpbloch
15 years ago

  • Cc johnpbloch added
  • Keywords WP_Query Post Types WP Permalinks removed

I need to update the patch. It's got some flaws in it.

#2 @mikeschinkel
15 years ago

  • Cc mikeschinkel@… added

Related: #12935

#3 @jorbin
15 years ago

  • Cc jorbin added
  • Component changed from Post Types to Permalinks
  • Milestone changed from Awaiting Review to Future Release

@johnpbloch
15 years ago

Refreshed Patch

#4 @nacin
14 years ago

  • Milestone Future Release deleted
  • Resolution set to wontfix
  • Status changed from new to closed

wontfix based on #13818 and a conversation with John. The rest of this is plugin territory.

Note: See TracTickets for help on using tickets.