[wp-trac] [WordPress Trac] #25798: Certain single CPT items result in 404 since 3.7

WordPress Trac noreply at wordpress.org
Fri Feb 21 17:36:44 UTC 2014


#25798: Certain single CPT items result in 404 since 3.7
-------------------------------+------------------------------
 Reporter:  boonebgorges       |       Owner:
     Type:  defect (bug)       |      Status:  new
 Priority:  normal             |   Milestone:  Awaiting Review
Component:  Posts, Post Types  |     Version:  3.7
 Severity:  normal             |  Resolution:
 Keywords:                     |     Focuses:
-------------------------------+------------------------------

Comment (by mordauk):

 After a quick test, it looks like passing the post type to
 `get_page_by_path()` [https://core.trac.wordpress.org/browser/trunk/src
 /wp-includes/class-wp.php#L209 here] fixes the issue:

 {{{
 if ( ! get_page_by_path( $matches[ $varmatch[1] ], OBJECT, 'bbg_test' ) )
 }}}

  I just hard coded the post type to test it quickly and it resolved the
 404 error.

--
Ticket URL: <https://core.trac.wordpress.org/ticket/25798#comment:2>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform


More information about the wp-trac mailing list