wp_list_bookmarks should always show name if there is no image to show. Props mtdewvirus. fixes #7981
git-svn-id: http://svn.automattic.com/wordpress/trunk@9366 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
parent
8b07a301c5
commit
611bbf9955
|
@ -51,7 +51,7 @@
|
||||||
function _walk_bookmarks($bookmarks, $args = '' ) {
|
function _walk_bookmarks($bookmarks, $args = '' ) {
|
||||||
$defaults = array(
|
$defaults = array(
|
||||||
'show_updated' => 0, 'show_description' => 0,
|
'show_updated' => 0, 'show_description' => 0,
|
||||||
'show_images' => 1, 'show_name' => 1,
|
'show_images' => 1, 'show_name' => 0,
|
||||||
'before' => '<li>', 'after' => '</li>', 'between' => "\n",
|
'before' => '<li>', 'after' => '</li>', 'between' => "\n",
|
||||||
'show_rating' => 0, 'link_before' => '', 'link_after' => ''
|
'show_rating' => 0, 'link_before' => '', 'link_after' => ''
|
||||||
);
|
);
|
||||||
|
@ -105,9 +105,11 @@ function _walk_bookmarks($bookmarks, $args = '' ) {
|
||||||
$output .= "<img src=\"$bookmark->link_image\" $alt $title />";
|
$output .= "<img src=\"$bookmark->link_image\" $alt $title />";
|
||||||
else // If it's a relative path
|
else // If it's a relative path
|
||||||
$output .= "<img src=\"" . get_option('siteurl') . "$bookmark->link_image\" $alt $title />";
|
$output .= "<img src=\"" . get_option('siteurl') . "$bookmark->link_image\" $alt $title />";
|
||||||
}
|
|
||||||
|
|
||||||
if ($show_name) $output .= $name;
|
if ($show_name) $output .= $name;
|
||||||
|
} else {
|
||||||
|
$output .= $name;
|
||||||
|
}
|
||||||
|
|
||||||
$output .= $link_after;
|
$output .= $link_after;
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue