Thursday, October 30, 2003

Changes to the blog

I’ve been doing some tweaking to this blog in the past couple days, experimenting with some “Movable Type” plugins to extend the functionality of this site. Some new items:

  • Installed MT-Amazon, a plugin that lets me link this blog to using the Amazon web services API. Without the technobabble, that means that I can trigger look-ups to Amazon when the blog publishes, and Amazon will populate the blog with the appropriate info.

  • To extend MT-Amazon, I also installed Brad Choate’s MTMacro plugin, which lets you define macros that will perform magic. By following Brad’s example, I can now create a tag called “Amazon” that will let me create a link to Amazon without having to remember my Associates ID, or how to format the URL to the book. To link to a book by John Grisham, I just enter in:

<amazon keyword=“John Grisham”>John Grisham</amazon>

The result looks like this: John Grisham

(Note the pop-up window, populated by the book cover, price, and link to buy the book? That’s using MTMacro to query via the web services API, then passing the data through to the Overlib Javascript applet for display.)

  • Update (10/31 10:20am): Seems like Amazon’s Web Services are down; I’ve been getting error messages all morning. Until further notice, I’m disabling this functionality. Oh well. **

I had looked at MTMacro a while ago, but had some trouble understanding how it could help me. Now I’m starting to see just how powerful it really is — it lets me extend my weblog in any direction I want. I need to give this some more thought, but there’s huge potential in using this to push Movable Type well beyond simple weblog publishing.

In all likelihood, more changes are coming: friendlier archive URLs (no more numbers!), creating a weblog that tracks all articles I’ve ever written (finally), breaking up my Movable Type templates into a series of modules that can be bulit by using the MTInclude command (which will make the site a true template-driven site with as little repeated code as possible), and more…


  1. I'm not sure I get it - how does it know *which* John G. book to link to?

  2. Steven - It'll link to the most popular if you use a keyword search; you can also link to the ASIN.

    Note - as of this morning, I'm experiencing some problems with Amazon web services. I don't think it's on my end - but the error messages I'm getting in Movable Type aren't particularly helpful (it appears that I'm either getting no XML back from Amazon, or improperly formatted XML). Whatever the case, it's preventing me from republishing the site with the Amazon mark-up.

    Hopefully this is an isolated instance; as cool as this particular hack is I'll probably have to remove it if it persists.