Author image
Senior Mind

Adding text to the Drupal feed icon

Drupal's handling of RSS's feeds is generall excellent, BUT sometimes it's nice to add a bit of explanation text to the standard orange feed icon. Add this little snippet to your template.php file and you can add a bit of text to your Drupal feed icon.

function phptemplate_feed_icon($url) {
  if ($image = theme('image', 'misc/feed.png', t('Syndicate content'), t('Syndicate content'))) {
    return '<a href="'. check_url($url) .'" class="feed-icon">'. $image. ' RSS feed</a>';