Update: There are newer versions available; please use the newest version unless you have a particular reason not to.
Next up: AllConsuming (books).
Unlike most the other plugins I’ve released, I haven’t tried hard this time to stick to core Perl modules: it requires Storable (with working lock_retrieve and lock_store), SOAP::Lite and Algorithm::Numerical::Shuffle. These requirements might be lowered in later releases.
Storable is required because I don’t think anybody would want to use this without caching. Looking up the information is pretty slow, and you don’t want a random user to have to wait for it.
SOAP::Lite is required because AllConsuming’s API is SOAP based. Algorithm::Numerical::Shuffle is required for random selection from long lists — that one could be removed easily, but as long as I’m requiring people to get SOAP working, adding one more easy install didn’t seem too bad.
Installation
- Verify you have the necessary modules installed; install them if not.
- download and unzip the plugin.
- Copy the plugin to your plugins directory
- Configure the username variable; it won’t do anything until you do.
- Add $allconsuming::reading, $allconsuming::finished, or the like to one of your flavour files. See the included POD documentation (perldoc allconsuming) for the complete list.
- If you’re an Amazon Associate, modify the template to use your ID instead of mine (’mtmolel-20′); if you aren’t, but don’t want to give me gratuitous hits, just remove the ‘/mtmolel-20′ bit from the template
- Try it out — load your blog in your browser.
- If everything is working, set $debug_level to 1; if not, check your error log to make sure the plugin is being loaded, and see if it’s logging any errors from the Netflix site
- Drop me a note letting me you’re using it and how things are working for you.
- Enjoy!
Things still to do, maybe:
- have a variable for the amazon associate ID rather than hardcoding mine in the default template — oops, I meant to get that into the first release, honest.
- locally cache the amazon image files, and supply the width and height; my previous non-plugin method did this, but I just haven’t gotten to it for this.
- use the (less-documented, less-official?) CGI-based AllConsuming API rather than the SOAP, and do XML parsing with regexes, to get the module requirements down to something sane.
- if the above has been done, make the shuffling support optional, and don’t require Shuffle if it’s not wanted.
- if/when blosxom supports it, use a plugged-in interpolate function, so interpolate-conditional can be used to conditionally include images based on the list (my previous non-plugin method did this, too, but there’s no sane way to do it in a plugin, yet)