Amazon Plugin

amazon plugin by Andreas Gohr
Display product information fetched from Amazon for single products or lists

Last updated on 2008-11-01. Provides Syntax.
Compatible with DokuWiki 2007-06-26+.

Conflicts with amazon_heavy!
Similar to isbn.

Tagged with amazon, asin, books, isbn, listmania, wishlist.

This plugin allows you to include information and cover art form Amazon into a wiki page. This is somewhat similar to the ISBN plugin but it uses Amazon's WebService API to fetch the data. You can adjust the plugin's output by changing the format function of the plugin.

Download and Installation

Please use the following URL to download the plugin with the plugin manager or to install it manually:

Changes

Usage

Amazon Plugin Screenshot

Usage is simple - just use the amazon tag providing an ASIN as shown below:

{{amazon>0142000280}}

If you want to link to a national Amazon, use the following syntax to access the German, UK, Japanese, French or Canadian Amazon site.

{{amazon>de:0142000280}}
{{amazon>uk:0142000280}}
{{amazon>jp:0142000280}}
{{amazon>fr:0142000280}}
{{amazon>ca:0142000280}}

Wishlists or “ListMania” lists can be displayed using the wishlist or amazonlist keywords followed by the list id. Country support works the same as with single products above. Examples:

{{wishlist>de:11ACQWWKWOM3G}}
{{amazonlist>R2AD3IPI9YY0TO}}

The default configuration options set in the config manager can be overridden by giving additional space separated keywords:

{{wishlist>de:11ACQWWKWOM3G price =0 90x90}}
{{amazon>0142000280 noprice =40 50x70}}

The following keywords can be used:

widthxheight the size of the shown image(s)
=number limit outputs to this number of characters, set to 0 for no limit
noprice don't show product prices
price show product prices
nopurchased exclude already purchased items
purchased include already purchased items
sortprice sort items ordered by price, cheapest on top
sortpopularity sort items by personal popularity as provided by list owner
sortadded sort items by the date they were added, newest on top

Configuration

Everything is configurable through the config manager. You can specify the width and height of images and if you want to display prices here. You can set up Amazon Partner IDs for all supported shops. If you feel generous, leave in the IDs of the plugin author.

Note: It is recommended to enable the fetchsize option to get correct rescaling for the external images.

Some more info

The plugin uses the Amazon Webservice API. To access this API one needs to have a valid developer key issued by Amazon.com. This key is set as the AMAZON_APIKEY define at the very top. You can use the one set in the code which is mine as long as you don't change the way the API is queried. If you want to change the Amazon access methods I ask you to register your own ID.

Ben Pollinger created a button that could be used with this plugin in the toolbar

 
plugin/amazon.txt · Last modified: 2008/12/07 18:08 by foosel
 

Except where otherwise noted, content on this wiki is licensed under the following license: CC Attribution-Noncommercial-Share Alike 3.0 Unported

Imprint Recent changes RSS feed Donate Powered by PHP Valid XHTML 1.0 Valid CSS Driven by DokuWiki
WikiForumIRCBugsDarcsXRefTranslate