summaryrefslogtreecommitdiffstats
path: root/wp-includes/bookmark-template.php
diff options
context:
space:
mode:
Diffstat (limited to 'wp-includes/bookmark-template.php')
-rw-r--r--wp-includes/bookmark-template.php9
1 files changed, 6 insertions, 3 deletions
diff --git a/wp-includes/bookmark-template.php b/wp-includes/bookmark-template.php
index 446ea46..c5c2505 100644
--- a/wp-includes/bookmark-template.php
+++ b/wp-includes/bookmark-template.php
@@ -319,12 +319,15 @@ 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' => '<h2>', 'title_after' => '</h2>',
- 'category_orderby' => 'name', 'category_order' => 'ASC');
+ 'category_orderby' => 'name', 'category_order' => 'ASC', 'class' => 'linkcat');
$r = array_merge($defaults, $r);
extract($r);
$output = '';
+ if ( is_array($class) )
+ $class = trim(join(' ', $class));
+
if ( $categorize ) {
//Split the bookmarks into ul's for each category
$cats = get_categories("type=link&category_name=$category_name&include=$category&orderby=$category_orderby&order=$category_order&hierarchical=0");
@@ -333,7 +336,7 @@ 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_inivisible&show_updated=$show_updated");
if ( empty($bookmarks) )
continue;
- $output .= "<li id='linkcat-$cat->cat_ID' class='linkcat'>$title_before$cat->cat_name$title_after\n\t<ul>\n";
+ $output .= "<li id='linkcat-$cat->cat_ID' class='$class'>$title_before$cat->cat_name$title_after\n\t<ul>\n";
$output .= _walk_bookmarks($bookmarks, $r);
$output .= "\n\t</ul>\n</li>\n";
}
@@ -342,7 +345,7 @@ function wp_list_bookmarks($args = '') {
$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 .= "<li id='linkuncat' class='linkcat'>$title_before$title_li$title_after\n\t<ul>\n";
+ $output .= "<li id='linkuncat' class='$class'>$title_before$title_li$title_after\n\t<ul>\n";
$output .= _walk_bookmarks($bookmarks, $r);
$output .= "\n\t</ul>\n</li>\n";
}