From f8a932ae40bd6f733e7017c7d72b73e4489e4c30 Mon Sep 17 00:00:00 2001 From: michelvaldrighi Date: Tue, 12 Aug 2003 22:23:33 +0000 Subject: [PATCH] fixed: filters applied several times on the_title* functions git-svn-id: https://develop.svn.wordpress.org/trunk@308 602fd350-edb4-49c9-b593-d223f7449a82 --- b2-include/b2template.functions.php | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) diff --git a/b2-include/b2template.functions.php b/b2-include/b2template.functions.php index 07f33357cb..1ecc7ac5fa 100644 --- a/b2-include/b2template.functions.php +++ b/b2-include/b2template.functions.php @@ -494,9 +494,10 @@ function the_title($before='', $after='') { $title = convert_bbcode($title); $title = convert_gmcode($title); $title = convert_smilies($title); - $title = apply_filters('the_title', $title); if ($title) { - echo convert_chars($before.$title.$after, 'html'); + $title = convert_chars($before.$title.$after); + $title = apply_filters('the_title', $title); + echo $title; } } function the_title_rss() { @@ -512,15 +513,15 @@ function the_title_unicode($before='',$after='') { $title = get_the_title(); $title = convert_bbcode($title); $title = convert_gmcode($title); - $title = apply_filters('the_title_unicode', $title); - if (trim($title)) { - echo convert_chars($before.$title.$after, 'unicode'); + if ($title) { + $title = convert_chars($before.$title.$after); + $title = apply_filters('the_title_unicode', $title); + echo $title; } } function get_the_title() { global $id, $post; $output = stripslashes($post->post_title); - $output = apply_filters('the_title', $output); return($output); }