From 94804af59a2e6919e1cc57cec78da82f6695c713 Mon Sep 17 00:00:00 2001 From: Ryan Boren Date: Mon, 21 Nov 2005 02:08:59 +0000 Subject: [PATCH] Run attachment filter for themes that don't have single.php or page.php. Props podz. fixes #1924 git-svn-id: https://develop.svn.wordpress.org/trunk@3174 602fd350-edb4-49c9-b593-d223f7449a82 --- wp-includes/template-loader.php | 2 ++ 1 file changed, 2 insertions(+) diff --git a/wp-includes/template-loader.php b/wp-includes/template-loader.php index fcab1a8a58..f503f37e4e 100644 --- a/wp-includes/template-loader.php +++ b/wp-includes/template-loader.php @@ -48,6 +48,8 @@ if ( defined('WP_USE_THEMES') && constant('WP_USE_THEMES') ) { include(get_paged_template()); exit; } else if ( file_exists(TEMPLATEPATH . "/index.php") ) { + if ( is_attachment() ) + add_filter('the_content', 'prepend_attachment'); include(TEMPLATEPATH . "/index.php"); exit; }