Make WordPress Core

Opened 13 years ago

Closed 11 years ago

#1508 closed defect (bug) (worksforme)

permalink clash postname and post_id

Reported by: Viitoria Owned by: markjaquith
Milestone: Priority: normal
Severity: normal Version:
Component: General Keywords: dev-feedback 2nd-opinion
Focuses: Cc:


When %postname% and %post_id% are defined in the permalink url, content fails to show up on the permalinked page. They refuse to work together.

Change History (5)

#1 @markjaquith
13 years ago

  • Keywords bg|dev-feedback bg|2nd-opinion added
  • Owner changed from anonymous to markjaquith
  • Status changed from new to assigned

Verified in WordPress 1.6

/%postname%/%post_id%/ doesn't work, but /%post_id%/%postname%/ does.

This likely has to do with the fact that a post like /post-name/11/ looks like the 11th page of /post-name/

#2 @markjaquith
13 years ago

We might have to just list what rewrite structures we're going to accept and which ones we won't (or can't, without making the code extremely complex.)

Reminder to self: create checkboxes of common, supported rewrite structures on Options => Permalinks and call the user-supplied permalink structure box "Custom (Advanced User s Only)" with a link to a Codex page discussing which structures will work and which won't.

#3 @markjaquith
13 years ago

Okay, Matt checked in a change that lists two commonly used permalink schemes (as bullets).

Next: create codex page discussing which permalink structures work, and which ones don't.

#4 @rob1n
11 years ago

  • Keywords dev-feedback 2nd-opinion added; permalinks bg|dev-feedback bg|2nd-opinion removed

I don't see how we can fix this, short of hacking a bit of code up. /postname/id doesn't really make sense, anyways...

#5 @johnbillion
11 years ago

  • Resolution set to worksforme
  • Status changed from assigned to closed

Closing as worksforme. %postname% and %post_id% can be used together in the permalink structure. Tested on Apache and IIS with no problems.

Note: See TracTickets for help on using tickets.