You could do this much simpler like this:
<?php $comments = get_comments('status=approve&number=5'); ?>
<ul>
<?php foreach ($comments as $comment) { ?>
<li>
<?php echo get_avatar( $comment, '35' ); ?>
<a href="<?php echo get_permalink($comment->ID); ?>#comment-<?php echo $comment->comment_ID; ?>" title="on <?php echo $comment->post_title; ?>"> <?php echo strip_tags($comment->comment_author); ?>: <?php echo wp_html_excerpt( $comment->comment_content, 35 ); ?>... </a>
</li>
<?php } ?>
</ul>
Ok, here’s some code explanations:
$comments = get_comments('status=approve&number=5')
-> get 5 latest commentsget_avatar( $comment, '35' )
-> get and display avatar with 35x35px sizeget_permalink($comment->ID)
and$comment->comment_ID
-> get the link to the commentstrip_tags($comment->comment_author)
-> display comment authorwp_html_excerpt( $comment->comment_content, 35 )
-> display the comments up to 35 characters