function theme_feed_icon
Same name and namespace in other branches
- 6.x drupal-6.x/includes/theme.inc \theme_feed_icon()
Returns HTML for a feed icon.
Parameters
$variables: An associative array containing:
- url: An internal system path or a fully qualified external URL of the feed.
- title: A descriptive title of the feed.
Related topics
1 call to theme_feed_icon()
- FeedIconTest::testFeedIconEscaping in drupal-7.x/
modules/ simpletest/ tests/ common.test - Check that special characters are correctly escaped. Test for issue #1211668.
4 theme calls to theme_feed_icon()
- aggregator_page_sources in drupal-7.x/
modules/ aggregator/ aggregator.pages.inc - Page callback: Displays all the feeds used by the aggregator.
- drupal_add_feed in drupal-7.x/
includes/ common.inc - Adds a feed URL for the current page.
- node_block_view in drupal-7.x/
modules/ node/ node.module - Implements hook_block_view().
- template_preprocess_aggregator_feed_source in drupal-7.x/
modules/ aggregator/ aggregator.pages.inc - Processes variables for aggregator-feed-source.tpl.php.
Archivo
- drupal-7.x/
includes/ theme.inc, line 2159 - The theme system, which controls the output of Drupal.
Código
function theme_feed_icon($variables) {
$text = t('Subscribe to !feed-title', array('!feed-title' => $variables['title']));
if ($image = theme('image', array('path' => 'misc/feed.png', 'width' => 16, 'height' => 16, 'alt' => $text))) {
return l($image, $variables['url'], array('html' => TRUE, 'attributes' => array('class' => array('feed-icon'), 'title' => $text)));
}
}