summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--includes/common.inc4
-rw-r--r--includes/theme.inc11
-rw-r--r--modules/aggregator/aggregator.module2
-rw-r--r--modules/node/node.module2
4 files changed, 12 insertions, 7 deletions
diff --git a/includes/common.inc b/includes/common.inc
index f8b7150a4..37fc16320 100644
--- a/includes/common.inc
+++ b/includes/common.inc
@@ -163,7 +163,7 @@ function drupal_add_feed($url = NULL, $title = '') {
static $stored_feed_links = array();
if (!is_null($url)) {
- $stored_feed_links[$url] = theme('feed_icon', $url);
+ $stored_feed_links[$url] = theme('feed_icon', $url, $title);
drupal_add_link(array('rel' => 'alternate',
'type' => 'application/rss+xml',
@@ -2417,7 +2417,7 @@ function drupal_common_themes() {
'arguments' => array('url' => NULL),
),
'feed_icon' => array(
- 'arguments' => array('url' => NULL),
+ 'arguments' => array('url' => NULL, 'title' => NULL),
),
'closure' => array(
'arguments' => array('main' => 0),
diff --git a/includes/theme.inc b/includes/theme.inc
index 442d91dc9..eb73fda0c 100644
--- a/includes/theme.inc
+++ b/includes/theme.inc
@@ -1300,9 +1300,14 @@ function theme_xml_icon($url) {
/**
* Return code that emits an feed icon.
- */
-function theme_feed_icon($url) {
- if ($image = theme('image', 'misc/feed.png', t('Syndicate content'), t('Syndicate content'))) {
+ *
+ * @param $url
+ * The url of the feed.
+ * @param $title
+ * A descriptive title of the feed.
+ */
+function theme_feed_icon($url, $title) {
+ if ($image = theme('image', 'misc/feed.png', t('Syndicate content'), $title)) {
return '<a href="'. check_url($url) .'" class="feed-icon">'. $image .'</a>';
}
}
diff --git a/modules/aggregator/aggregator.module b/modules/aggregator/aggregator.module
index 659771a6e..9fe240734 100644
--- a/modules/aggregator/aggregator.module
+++ b/modules/aggregator/aggregator.module
@@ -1325,7 +1325,7 @@ function aggregator_page_categories() {
*/
function theme_aggregator_feed($feed) {
$output = '<div class="feed-source">';
- $output .= theme('feed_icon', $feed->url) ."\n";
+ $output .= theme('feed_icon', $feed->url, t('!title feed', array('!title' => $feed->title))) ."\n";
$output .= $feed->image;
$output .= '<div class="feed-description">'. aggregator_filter_xss($feed->description) ."</div>\n";
$output .= '<div class="feed-url"><em>'. t('URL:') .'</em> '. l($feed->link, $feed->link, array('absolute' => TRUE)) ."</div>\n";
diff --git a/modules/node/node.module b/modules/node/node.module
index 8e57856af..37561629e 100644
--- a/modules/node/node.module
+++ b/modules/node/node.module
@@ -1836,7 +1836,7 @@ function node_block($op = 'list', $delta = 0) {
}
else if ($op == 'view') {
$block['subject'] = t('Syndicate');
- $block['content'] = theme('feed_icon', url('rss.xml'));
+ $block['content'] = theme('feed_icon', url('rss.xml'), t('Syndicate'));
return $block;
}