From 677a576cdb73b72d237886b85d1449252708d97c Mon Sep 17 00:00:00 2001 From: rboren Date: Sun, 13 Feb 2005 21:20:00 +0000 Subject: [PATCH] Process feed and trackback templates even if not using themes. git-svn-id: http://svn.automattic.com/wordpress/trunk@2304 1a063a9b-81f0-0310-95a4-ce76da25c4cd --- wp-blog-header.php | 24 ++++++++++++------------ 1 file changed, 12 insertions(+), 12 deletions(-) diff --git a/wp-blog-header.php b/wp-blog-header.php index f25d1f98ed..70ebeb8c0e 100644 --- a/wp-blog-header.php +++ b/wp-blog-header.php @@ -4,6 +4,8 @@ if (! isset($wp_did_header)): if ( !file_exists( dirname(__FILE__) . '/wp-config.php') ) die("There doesn't seem to be a wp-config.php file. I need this before we can get started. Need more help? We got it. You can create a wp-config.php file through a web interface, but this doesn't work for all server setups. The safest way is to manually create the file."); +$wp_did_header = true; + require_once( dirname(__FILE__) . '/wp-config.php'); $query_vars = array(); @@ -183,21 +185,9 @@ if ( (0 == count($posts)) && !is_404() && !is_search() if ( is_trackback() ) $doing_trackback = true; -$wp_did_header = true; -endif; - -$wp_template_dir = TEMPLATEPATH; - // Template redirection if ( defined('WP_USE_THEMES') && constant('WP_USE_THEMES') ) { do_action('template_redirect'); - if ( is_feed() && empty($doing_rss) ) { - include(ABSPATH . '/wp-feed.php'); - exit; - } else if ( is_trackback() ) { - include(ABSPATH . '/wp-trackback.php'); - exit; - } if ( is_feed() && empty($doing_rss) ) { include(ABSPATH . '/wp-feed.php'); exit; @@ -238,6 +228,15 @@ if ( defined('WP_USE_THEMES') && constant('WP_USE_THEMES') ) { include(TEMPLATEPATH . "/index.php"); exit; } +} else { + // Process feeds and trackbacks even if not using themes. + if ( is_feed() && empty($doing_rss) ) { + include(ABSPATH . '/wp-feed.php'); + exit; + } else if ( is_trackback() ) { + include(ABSPATH . '/wp-trackback.php'); + exit; + } } if ($pagenow != 'post.php' && $pagenow != 'edit.php') { @@ -245,4 +244,5 @@ if ($pagenow != 'post.php' && $pagenow != 'edit.php') { gzip_compression(); } +endif; ?> \ No newline at end of file