diff --git a/wp-includes/theme.php b/wp-includes/theme.php index e6a6f28597..a5bf8e0d43 100644 --- a/wp-includes/theme.php +++ b/wp-includes/theme.php @@ -342,6 +342,7 @@ function get_theme_root_uri() { function get_query_template($type) { $template = ''; + $type = preg_replace( '|[a-z0-9-]+|', '', $type ); if ( file_exists(TEMPLATEPATH . "/{$type}.php") ) $template = TEMPLATEPATH . "/{$type}.php";