RSS Cacheing Rewriting Proxy

We were struggling with the RSS channel that is delivered with Luminis III. It doesn't support newer feed formats, and it's a resource hog. So to compensate, we use the attached proxy script.

It does a two major things:

1) Consumes a larger variety of feed formats (like Atom and RSS 2.0) and rewrites them to RSS 1.0, which can then be used in the portal RSS channel

2) Caches the feed so that load on the remote feed server is minimized, network traffic is minimized, and the user experience is improved because it's usually faster to deliver the feed from a local cache

It also has a few nice features that we use, like overriding the feed image or trimming the feed description, in those cases where the (usually local) feed authors aren't interested in providing quality feed information themselves. The help documentation is built in, just download the file and view the source to see.

You will have to install the two required packages to use this script. It's pretty self-explanatory when you view the source.

Enjoy!

Todd

0
No votes yet

Comment viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.

Slight bug fix

Great tool, this is exactly what we needed for our Luminis portal. Everybody should know about this because it's one of the main gripes about Luminis, only support for RSS <1.0! Easy to set up and use.

I did find one slight bug in your script. The option to get all items by setting the item parameter to '0' did not work. It simply returned zero items. I edited the file so that '0' returns no items, while any negative number returns all the available items. I also cleaned up the script to remove some code that was specific to your university's site. Finally, I turned Magpie's error reporting level to '0' so that it works right out of the box. I'll post a new comment with the file as an attachment and link to is in a subsequent comment here.

Thanks, great work!

Link to bugfix

Get the bugfix in this post.

Great Script

Hey Todd. Great script but I noticed some feeds (not all) URL encode things like &quot so that the translated feed does not actually show the character but the HTML encoded value. Is there any way for the translated feed to show through the proper characters? Example of a feed not translating properly: http://developers.sun.com/rss/creator.xml. Feed it through the feed2rss.php script and watch the title lines for encoded values. There are other feeds that have no problem with things like quotes.

Tony

fix?

have you found/made a fix for this?

Testing this

Yes, we have noticed that some characters do get improperly translated some of the time. However, the feed that you have given is a moving target... if you want to test this together, then take a copy of a feed that isn't working, save it to one of your local servers, and then give that URL to me. That way, we're both looking at the same thing and perhaps we can fix this.

When I went to look at this particular feed today, I didn't actually see any bugs. There were certainly items with &quot entities that weren't being properly displayed, but these entries were messed up in the original feed.

Todd