In which I dive into the WordPress codebase

WordPress Mod:  Amazon QuickTags

I wanted to add nifty little Amazon links to my posting window … so I did. Grab my zipped version of quicktags.js and you can, too. This is the javascript file that builds the row of buttons above your posting window (e.g. str, em, del, etc.) My version adds two buttons: one for quick-linking to an item at Amazon via its ASIN and one for quick-linking to an Amazon search.

Amazon ASIN LinkAmazon Search

If your site blows up, don’t come crying to me.

Just replace the version of quicktags.js that is in your wp-admin folder (moved to wp-includes/js since WordPress 2.04) with the one in my zip file and stick the images in wp-images. If your site blows up, don’t come crying to me. You’re hacking now, kid. It’s pretty straight-forward, though, and if you’re slick enough to understand what I’m typing here you’re most likely slick enough to get it to work without breaking anything. I added a variable to the top of the .js file so you can use your own Amazon associates id. Feel free to use mine, of course — I love cash.

I’ve included the two images in the zip file, so please don’t hard-link to my site for them.

WordPress is just really amazing. I am loving it!

From the “Give Credit Where Credit Is Due Department”: Original concept via Scott Andrew

There are 4 comments on this post

  1. Thanks for the nifty mod.

    A note to others who may add this to their site. Using Firefox v1.0.1 I had to clear the browser cache before the Amazon tags appeared above the post entry box.

    So if you install this mod and it doesn’t appear to be adding the two amazon buttons then try clearing the cache first.

    Later folks,

  2. […] Für die persönliche Wunschliste Programmiert von […]

  3. I realise this plug-in is waaaaaay old, but is there a version which handles the 2.x system for WordPress? While this version doesn’t blow it up, it doesn’t seem to activate either.

  4. Hey, that’s cool how you require to type in a code in order to type. I’ll have to look for that plug in so I don’t have to moderate all the spam comments!

    Just thought I’d also mention that this plug in doesn’t activate for the latest version of Word Press (2.0.4). I tried it in both Firefox (cleared the cache) and MSIE. Too bad. The other Amazon plug in I found doesn’t totally work either. It pops up a tool that lets you search for a product, then it’s supposed to put the html into your post, but that part doesn’t work. I just copy and paste the html from the amazon tool into the html tool of Word press. Not too bad. Here’s the link to the amazon plug:

Add to the discussion:

I'll never share your email address and it won't be published.

What Is This? is the personal weblog of me, David Vincent Gagne. I've been publishing here since 1999, which makes this one of the oldest continuously-updated websites on the Internet.

A few years ago I was trying to determine what cocktails I could make with the alcohol I had at home. I searched the App Store but couldn't find an app that would let me do that, so I built one.


You can read dozens of essays and articles and find hundreds of links to other sites with stories and information about Ernest Hemingway in The Hemingway Collection.