$vars['links'] is generated by theme_links(). Look at template_preprocess_node() in includes/theme.inc: http://drupalcode.org/viewvc/drupal/drupal/includes/theme.inc?revision=1.415.2.27&view=markup&pathrev=DRUPAL-6-18-SECURITY#l1955

$variables['links']     = !empty($node->links) ? theme('links', $node->links, array('class' => 'links inline')) : '';

Unless you absolutely consider the icons to be content and not styling, CSS is the way to go instead of <img> tags. Different CSS classes may be applied via theme_links() to indicate whether comments exist. CSS also allows for the use of sprites.

On Thu, Nov 18, 2010 at 12:27 PM, Salvatore De Paolis <iwkse@gmx.com> wrote:
On Thu, 18 Nov 2010 10:57:26 -0800 (PST)
nan wich <nan_wich@bellsouth.net> wrote:

Hi,

> You can do it in the CSS. Something like:
> .infoAndActions ul li.comment_add,
> .infoAndActions li.comment_comments {
>   background:
> url(/sites/all/themes/forresterblogs/images/infoAndActions_commentCount.gif)
> no-repeat left 8px;
>   padding-left: 29px;
>   margin-left: .3em;
> }
>
>
>  
> Nancy

Yes thanks I could do this way, but I need more control over it.
For example when no comments, I'd only like to show the icon and
the text in the tooltip.