From d27f6e58e6754ed949ffe3ba7ed7f3cd956c59a6 Mon Sep 17 00:00:00 2001 From: ryan Date: Sun, 3 Apr 2005 05:43:42 +0000 Subject: [PATCH] Path info permalinks weren't getting 404 treatment. git-svn-id: http://svn.automattic.com/wordpress/trunk@2510 1a063a9b-81f0-0310-95a4-ce76da25c4cd --- wp-blog-header.php | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/wp-blog-header.php b/wp-blog-header.php index 69cf2979da..26c9004bab 100644 --- a/wp-blog-header.php +++ b/wp-blog-header.php @@ -183,8 +183,8 @@ if ( is_single() || is_page() ) { // 404 if one was already issued, if the request was a search, or if the // request was a regular query string request rather than a permalink request. if ( (0 == count($posts)) && !is_404() && !is_search() - && !empty($_SERVER['QUERY_STRING']) && - (false === strpos($_SERVER['REQUEST_URI'], '?')) ) { + && ( isset($rewrite) || (!empty($_SERVER['QUERY_STRING']) && + (false === strpos($_SERVER['REQUEST_URI'], '?'))) ) ) { $wp_query->is_404 = true; if ( preg_match('/cgi/', php_sapi_name()) ) @header('Status: 404 Not Found'); @@ -231,6 +231,7 @@ if ( defined('WP_USE_THEMES') && constant('WP_USE_THEMES') ) { include(get_date_template()); exit; } else if ( is_archive() && get_archive_template() ) { + echo "here"; include(get_archive_template()); exit; } else if ( is_comments_popup() && get_comments_popup_template() ) {