[wp-trac] [WordPress Trac] #14324: 404 when querying custom post types on author.php

WordPress Trac wp-trac at lists.automattic.com
Thu Jul 15 23:31:31 UTC 2010


#14324: 404 when querying custom post types on author.php
--------------------------+-------------------------------------------------
 Reporter:  truthmedia    |       Owner:                                               
     Type:  defect (bug)  |      Status:  new                                          
 Priority:  normal        |   Milestone:  Awaiting Review                              
Component:  Post Types    |     Version:  3.0                                          
 Severity:  major         |    Keywords:  post_type, author.php, 404, custom post types
--------------------------+-------------------------------------------------

Comment(by truthmedia):

 On further analysis, the problem is a logical one, rather than a code
 based one.  WordPress initially determines what sort of page to display
 (ie author or 404) based on the query obtained by the URL.  Because this
 initial query has no post_type specified, it defaults to "post".  As such,
 the 404 is sent long before the code would even have a chance to reach our
 custom query.  I can probably devise a workaround, however this is still a
 business logic problem when custom queries are able to return more posts
 than the original page might have.

-- 
Ticket URL: <http://core.trac.wordpress.org/ticket/14324#comment:1>
WordPress Trac <http://core.trac.wordpress.org/>
WordPress blogging software


More information about the wp-trac mailing list