Make WordPress Core

Ticket #7981: links-show-names.diff

File links-show-names.diff, 1012 bytes (added by mtdewvirus, 18 years ago)
  • bookmark-template.php

     
    5151function _walk_bookmarks($bookmarks, $args = '' ) {
    5252        $defaults = array(
    5353                'show_updated' => 0, 'show_description' => 0,
    54                 'show_images' => 1, 'show_name' => 1,
     54                'show_images' => 1, 'show_name' => 0,
    5555                'before' => '<li>', 'after' => '</li>', 'between' => "\n",
    5656                'show_rating' => 0, 'link_before' => '', 'link_after' => ''
    5757        );
     
    105105                                $output .= "<img src=\"$bookmark->link_image\" $alt $title />";
    106106                        else // If it's a relative path
    107107                                $output .= "<img src=\"" . get_option('siteurl') . "$bookmark->link_image\" $alt $title />";
     108
     109                        if ($show_name) $output .= $name;
     110                } else {
     111                        $output .= $name;
    108112                }
    109113               
    110                 if ($show_name) $output .= $name;
    111 
    112114                $output .= $link_after;
    113115               
    114116                $output .= '</a>';
     
    249251        echo $output;
    250252}
    251253
    252 ?>
    253  No newline at end of file
     254?>