From 8f63b6f1716166713252d30952bd304b5788e72d Mon Sep 17 00:00:00 2001 From: mikelittle Date: Sun, 26 Oct 2003 00:35:45 +0000 Subject: [PATCH] Moved post count outside the link in monthly version of get_archives(). git-svn-id: http://svn.automattic.com/wordpress/trunk@469 1a063a9b-81f0-0310-95a4-ce76da25c4cd --- b2-include/b2template.functions.php | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/b2-include/b2template.functions.php b/b2-include/b2template.functions.php index 8d4af5aca3..43c498dc35 100644 --- a/b2-include/b2template.functions.php +++ b/b2-include/b2template.functions.php @@ -115,7 +115,7 @@ function get_archives_link($url, $text, $format = "html", $before = "", $after = } else if ('option' == $format) { return ''."\n"; } else if ('html' == $format) { - return "\t".'
  • '.$text.'
  • '."\n"; + return "\t".'
  • '.$text.''.$after.'
  • '."\n"; } else { // custom return "\t".$before.''.$text.''.$after."\n"; } @@ -165,10 +165,12 @@ function get_archives($type='', $limit='', $format='html', $before = "", $after if ($arcresults) { foreach ($arcresults as $arcresult) { $url = sprintf("%s%d%02d", $archive_link_m, $arcresult->year, $arcresult->month); - if ($show_post_count) - $text = sprintf("%s %d (%d)", $month[zeroise($arcresult->month,2)], $arcresult->year, $arcresult->posts); - else + if ($show_post_count) { $text = sprintf("%s %d", $month[zeroise($arcresult->month,2)], $arcresult->year); + $after = " ($arcresult->posts)"; + } else { + $text = sprintf("%s %d", $month[zeroise($arcresult->month,2)], $arcresult->year); + } echo get_archives_link($url, $text, $format, $before, $after); } }