diff options
author | Tim Almdal <tnalmdal@shaw.ca> | 2011-07-12 21:44:40 -0700 |
---|---|---|
committer | Tim Almdal <tnalmdal@shaw.ca> | 2011-07-12 21:44:40 -0700 |
commit | 51726f9e4b8372c40b27f843fca7b783e6db9623 (patch) | |
tree | fcc60c8caad19bbbb01043915103e85b33f31d6a /modules/gallery | |
parent | e8382b960a3c19bb28140833e348e6c9c9db8a8a (diff) |
Fix for ticket #1752. Add an RSS field link for the current album. Or, in the case of a photo or movie, add a link to the rss field of the parent album.
Diffstat (limited to 'modules/gallery')
-rw-r--r-- | modules/gallery/helpers/gallery_rss.php | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/modules/gallery/helpers/gallery_rss.php b/modules/gallery/helpers/gallery_rss.php index 612872e6..9af67118 100644 --- a/modules/gallery/helpers/gallery_rss.php +++ b/modules/gallery/helpers/gallery_rss.php @@ -21,6 +21,14 @@ class gallery_rss_Core { static function available_feeds($item, $tag) { $feeds["gallery/latest"] = t("Latest photos and movies"); + + if ($item) { + $feed_item = $item -> is_album() ? $item : $item->parent(); + + $feeds["gallery/album/{$feed_item->id}"] = + t("%title photos and movies", array("title" => $feed_item->title)); + } + return $feeds; } |