[wp-trac] [WordPress Trac] #12256: robots.txt not generated without posts
WordPress Trac
wp-trac at lists.automattic.com
Thu Feb 18 10:56:04 UTC 2010
#12256: robots.txt not generated without posts
--------------------------+-------------------------------------------------
Reporter: willshouse | Owner: ryan
Type: defect (bug) | Status: new
Priority: normal | Milestone: 3.0
Component: Query | Version: 2.8.6
Severity: normal | Keywords: needs-patch
--------------------------+-------------------------------------------------
Comment(by dd32):
On a robots request, WordPress appears to make a SQL request for the same
as it would on a Home index page.
handle_404() throws a 404 if there are 0 posts matched.
Ideally, WordPress should not query the database for posts on robots.txt
requests.
I'll commit a change to display the robots.txt page with 0 posts, but I'd
prefer to see something happen about that Querying.. It might require an
extra internal request var, along the lines of 'plugin-handled-no-404' or
something.. Pure thoughts there.
--
Ticket URL: <http://core.trac.wordpress.org/ticket/12256#comment:2>
WordPress Trac <http://core.trac.wordpress.org/>
WordPress blogging software
More information about the wp-trac
mailing list