I've been a technical director of a podcast for quite some time. I wanted to track podcast usage, and at the time I wasn't aware of services like podtrac.com. Even if I was, I'm wary of letting other domains be involved in how users end up listening to the podcast. So I've been working on a podcast tracking system. I'm not particularly looking for critique here, but it would be welcome - I'm just looking for ways to give others access to this system, if they're less technically inclined than most.
Anyways, you can download the package here. My feed is at http://dongbufeng.net/twilight/podcast/ ... leFeed.xml, so this system should be unzipped to the /podcast directory.
Usage: Any file in the /podcast directory can be tracked by replacing '/podcast/' with '/podcast/tracker/'. For example, you're hosting a ZIP file, and want it's downloads tracked. Instead of giving out the URL http://dongbufeng.net/twilight/podcast/files/foo.zip, give out http://dongbufeng.net/twilight/podcast/ ... es/foo.zip. It'll also pass through any URL arguments, and the arguments will be present in the log. The /counter/index.php file parses and aggregates the log file, giving an overall hit count, as well as per-file, per-IP, and per-country hit counts.
I also implemented a feed builder, making it much easier to add, edit, and delete episodes without ever having to work with the XML feed file. This tool, along with a collection of other useful links, is available at /admin/index.html.
Podcast Tracking System
Moderator: General Moderators
- Serpent_Guard
- Forum Newbie
- Posts: 6
- Joined: Mon Nov 24, 2008 2:07 pm
Podcast Tracking System
Last edited by Serpent_Guard on Sun Nov 30, 2008 11:22 am, edited 1 time in total.
Re: Podcast Tracking System
You use file based storage which isn't my cup of tea, but allows the application to be more portable. Kudos for sacrificing your sanity for the greater good of the user base. The code seems well implemented + designed for its purposes. I didn't actually fire it up but just skimmed through. I would use define() to define constants for some of the configuration settings, but that's just me. If you plan on making it more complicated you might want to look into a tiered approach where you template the presentation separate from the business logic. You could also provide adapters for using a relational database as well as file based storage, in case performance is a concern.