Possible bug in Media RSS

bubbanc

Joined: 2008-12-30
Posts: 9
Posted: Sun, 2009-01-25 16:30

I've been working on getting Gallery 2 RSS feeds to work with the Blogger Slideshow and wasn't having any luck. In comparing feeds with flickr and picasa to Gallery, I was able to determine the issue.

One issue is that in Gallery <media:thumbnail> is being set to the HTML link of the original picture instead of the thumbnail image. This was easily fixed.

$ diff modules/rss/classes/RssHelper.class.bak modules/rss/classes/RssHelper.class
302c302
< $itemSettings['thumbnail']['url'] = $url;
---
> $itemSettings['thumbnail']['url'] = $imageUrl;

Once this was fixed, I still had issues with Blogger. By removing the <media:text> portion of the feed, everything appeared to work fine.

$ diff modules/rss/classes/RssGenerator.class.bak modules/rss/classes/RssGenerator.class
308,311c308,311
< . '</media:title>' . $lf
< . ' <media:text type="html">'
< . $this->cdata(GalleryUtilities::markup($item['description']))
< . '</media:text>' . $lf;
---
> . '</media:title>' . $lf;
> #. ' <media:text type="html">'
> #. $this->cdata(GalleryUtilities::markup($item['description']))
> #. '</media:text>' . $lf;

I feel sure someone who knows more about proper RSS format, etc will have a look over this to determine if this is actually a bug or not. After these changes, the feed still appears to work fine in Google Reader and from within Firefox.

Bubba