Make WordPress Core

Opened 14 years ago

Closed 14 years ago

Last modified 14 years ago

#16807 closed defect (bug) (fixed)

with_front => false doesn't work with PATHINFO permalinks

Reported by: duck_'s profile duck_ Owned by:
Milestone: 3.1.1 Priority: normal
Severity: normal Version: 3.0
Component: General Keywords:
Focuses: Cc:

Description

When running WordPress with PATHINFO permalinks any plugin registering a custom post type or custom taxonomy using with_front => false in the rewrite argument just will not work since the /index.php is required.

/index.php cannot be treated like any other front since it is actually required for the permalinks to work.

We might want to internalize PATHINFO into WP_Rewrite so it doesn't get stripped like this.

Related: #16733

Attachments (3)

16807.diff (1.1 KB) - added by markjaquith 14 years ago.
16807.2.diff (1.7 KB) - added by markjaquith 14 years ago.
cpt-test.php (533 bytes) - added by markjaquith 14 years ago.
Drop this in mu-plugins (PHP5.3 required) to test.

Download all attachments as: .zip

Change History (10)

@markjaquith
14 years ago

@markjaquith
14 years ago

#1 @scribu
14 years ago

Also related: #16626

@markjaquith
14 years ago

Drop this in mu-plugins (PHP5.3 required) to test.

#2 @markjaquith
14 years ago

To test, drop cpt-test.php into mu-plugins. Set your permalink structure to start with:

(A) /index.php/

OR

(B) /index.php/archives/

Create a "Thing" entry called "thing-test"

Verify that http://wp.dev/index.php/things/ and http://wp.dev/index.php/things/thing-test/ work.

In the case of (B), you shouldn't see /archives/ appear in those URLs, because with_front is false.

#3 @ryan
14 years ago

I get the behavior you describe for that test plan. Looks good.

#5 @markjaquith
14 years ago

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

(In [17518]) Correctly handle PATHINFO CPTs and CTs that specify with_front=false. fixes #16807 for trunk

#6 @markjaquith
14 years ago

(In [17519]) Correctly handle PATHINFO CPTs and CTs that specify with_front=false. fixes #16807 for 3.1

#7 @nacin
14 years ago

  • Milestone changed from Awaiting Review to 3.1.1
Note: See TracTickets for help on using tickets.