diff --git a/wp-includes/bookmark-template.php b/wp-includes/bookmark-template.php
index c1540a3b3a..7c31ce5e0a 100644
--- a/wp-includes/bookmark-template.php
+++ b/wp-includes/bookmark-template.php
@@ -319,7 +319,8 @@ function wp_list_bookmarks($args = '') {
$defaults = array('orderby' => 'name', 'order' => 'ASC', 'limit' => -1, 'category' => '',
'category_name' => '', 'hide_invisible' => 1, 'show_updated' => 0, 'echo' => 1,
'categorize' => 1, 'title_li' => __('Bookmarks'), 'title_before' => '
', 'title_after' => '
',
- 'category_orderby' => 'name', 'category_order' => 'ASC');
+ 'category_orderby' => 'name', 'category_order' => 'ASC', 'class' => 'linkcat',
+ 'category_before' => '', 'category_after' => '');
$r = array_merge($defaults, $r);
extract($r);
@@ -333,18 +334,20 @@ function wp_list_bookmarks($args = '') {
$bookmarks = get_bookmarks("limit=$limit&category={$cat->cat_ID}&show_updated=$show_updated&orderby=$orderby&order=$order&hide_invisible=$hide_invisible&show_updated=$show_updated");
if ( empty($bookmarks) )
continue;
- $output .= "$title_before$cat->cat_name$title_after\n\t\n";
+ $output .= str_replace(array('%id', '%class'), array("linkcat-$cat->cat_ID", $class), $category_before);
+ $output .= "$title_before$cat->cat_name$title_after\n\t\n";
$output .= _walk_bookmarks($bookmarks, $r);
- $output .= "\n\t
\n
\n";
+ $output .= "\n\t\n$category_after\n";
}
} else {
//output one single list using title_li for the title
$bookmarks = get_bookmarks("limit=$limit&category=$category&show_updated=$show_updated&orderby=$orderby&order=$order&hide_invisible=$hide_inivisible&show_updated=$show_updated");
if ( !empty($bookmarks) ) {
- $output .= "$title_before$title_li$title_after\n\t\n";
+ $output .= str_replace(array('%id', '%class'), array("linkuncat", $class), $category_before);
+ $output .= "$title_before$title_li$title_after\n\t\n";
$output .= _walk_bookmarks($bookmarks, $r);
- $output .= "\n\t
\n
\n";
+ $output .= "\n\t\n$category_after\n";
}
}