Skip to content

Making a database-free online RSS reader in PHP

I follow a number of blogs and forums, and I've been looking for a while for a good way to pull the RSS feeds from most of these into one place for easy reading. On my Linux machine, QuiteRSS works really well. I like the features and interface, but I work on multiple computers throughout the day, and at night I read on my phone, so I really wanted one central place to go for checking up on things. Not wanting to reinvent the wheel, I went looking at the existing options, focusing on self-hosted solutions, because I really didn't want to throw all of that data into another for-profit site that would use my feeds to throw ads at me. And while I can deal with using a private server to install a fully-fledged RSS reader, I didn't really want to bother with logging into another service, then worry about updating it, and seeing that it is still maintained, etc. An RSS reader that stores a username/password combo is just one more security issue to worry about, and means that I'd have to make sure it's not easy to hack and get into. I'm not super concerned about being able to add new feeds on the fly, because I'm usually pretty close to web development tools, or I can wait until I get around to them--it's not the end of the world if I can't add something immediately.

So instead I decided to build my own. The scripts I've put together and modified work without a database because you must edit the file directly in order to add them, so the collection of feed is as secure as your site hosting is, plus there are no SQL calls to worry about. It's viewable anywhere you can run PHP, so there's no bother with logging into anything, and of course that means you can share it all you want just by sending people the link. Since it's all processed server-side, it basically acts like a static site for all intents and purposes, which was exactly what I wanted. There are some small downsides--right now it doesn't support Atom feeds, and there aren't any sorting options, but I'll probably come back to it and add those in the future.

I figured I might not be the only one wanting to do this, so I figured I'd share it here. Under the cut I've put a download link and a short explanation on how it works, so that you can add it to your own site if you like. Feel free to leave any questions you have in the comments. Continue reading "Making a database-free online RSS reader in PHP"