A Virtual Home

AVH Amazon

As of October 2010 this plugin is no longer working due to changes at Amazon (see article End of the AVH Amazon plugin?). I keep it here for historic reasons.

The AVH Amazon WordPress plugin gives you the ability to add a widget or use a shortcode in your post or page to display a random item from your Amazon wish list, baby registry and/or wedding registry.

Optionally you can change the Associated ID and or Wish List for this widget. This is for future implementation so you can have multiple widgets with different wish lists.

Support

If you have comments/problems/suggestions, see something in the code which is not compliant to the WordPress Plugin Codex, or just want to say “Cool! It works!”, feel free to create a post at the AVH Support Forum

FAQ

Q: What is my Wish List ID?
A: You can determine your Wish List ID by going to your Wish List page on Amazon. Click on the wish list you want to use in the plug in, even if you only have one wish list. The URL will show you something like this : http://www.amazon.com/gp/registry/wishlist/2CC2KKW02870/ref=cm_wl_rlist_go. This, 2CC2KKW02870 is your Wish List ID.

Q: What happens if I clear the Associated ID ?
A: The plugin will use my Associated ID and you will be supporting further development of the plugin.

Changelog

Version 3.2.1

Bugfix: Locale France didn’t work.

WordPress 3.0 compatibility

Bugfix: Randomize option didn’t stick

Version 3.2.0.1

Bugfix: Division by zero in admin section.

Version 3.2

RFC: Widget: Ability to disable the randomization of items in a wishlist.

RFC: Widget: Ability to select the sort order of the wishlist. Options are Last Updated, Date Added, Price (only cheapest to most expensive is allowed by Amazon) and Priority.

RFC: Removed line break tags in the wishlist widget after the image and caption.

RFC: Added Amazon.fr

Added caching. Wishlists and Items are cached for 23 hours to speed up the lookup process.

Version 3.1.1

Version 3.1

RFC: Ability to set number of columns when displaying all items from a wishlist.

The personal secret key is mandatory now. If it’s not present, the plugin will not work.

Version 3.0.8

Bugfix: Regression of Bugfix: When using the secret key, the call to Amazon would fail.

Version 3.0.7

Bugfix: In the tools section, when looking up your WishList ID and you only have one WishList an undefined function was called.

Version 3.0.6

New Amazon API version. Added the ability to see Universal Items on Wishlists.

Bugfix: Problem when showing shortcode and widget at the same page.

Version 3.0.5

Bugfix: When using the secret key, the call to Amazon would fail.

Version 3.0.4

Bugfix: When multiple pages of a list were retrieved and no AWS Key was supplied an error would occur.

Bugfix: Certain options weren’t saved in the widget.

Bugfix: Shortcodes didn’t work. Call to wrong class.

Version 3.0.3

If the plugin was installed prior to upgrading to WordPress 2.8, the widgets would disappear from the sidebars.

Version 3.0.2

Reported in conjunction with my AVH Extended Categories widget. The self class does not exists in getInstance.

Version 3.0.1

Conflict with declaration of sha256

Version 3.0

It uses the new Widget class introduced in WordPress 2.8.

Optimizations for WordPress 2.8.

Amazon policy change. Calls to Amazon need to be signed per August 15 of 2009. In order to sign calls you will need an Amazon Web Services account. See the FAQ for more details.

Picture is shown in metabox for ASIN search.

Use of WordPress defined variables, fixes problems when wp-content directory is moved.

Version 2.4

Speed improvements.

Increased security.

Reduced memory footprint.

RFC: Ability to select picture size in the short code.

Bugfix: Shortcode URL’s for items not in a awishlist were wrong.

Several other small bugs are fixed.

Version 2.3.4

Bugfix: Footer option in widget didn’t show.

Version 2.3.3

Bugfix: In the shortcode the default associate ID wasn’t set to the right one when using a a non US locale.

Version 2.3.2

Bugfix: The shortcode didn’t retrieve the assiocated ID set in the admin page.

Version 2.3.1

Bugfix: Certain character were not displayed correctly (Characters with Umlauts for example)

Version 2.3

RFC: When calling the widget directly the array parameter can hold the widget options.

Updated WDSL

With WordPress 2.7, when deleting the plugin it will clean up the database, removing the entries related the plugin.

Source code improvements.

Version 2.2.4

Bugfix: The footer in the widget wasn’t linking correctly.

Version 2.2.3

Bugfix: Metabox wasn’t displayed properly in WordPress 2.7

Version 2.2.2

Bugfix: Support for non-widget code was broken.

Bugfix: When running PHP 5 some warnings “Call-time pass-by-reference has been deprecated”

Version 2.2.1

Bugfix: Widget didn’t get the default values.

Version 2.2

Display a “no image available” picture when no picture is available.

Ability to set default settings for the shortcode.

Improve storage of the options.

Clear the cache folder at each upgrade.

Show searching indicator when searching for WishList or Asin in the Shortcode Metabox.

Bugfix: Fixed memory problem. Problem was not using avhamazon class in the shortcode.

Bugfix: Metabox was displayed incorrectly on the Page page.

RFC: Added option pic+text for the linktype parameter in the shortcode.

RFC: Added option all for the asin parameter in the shortcode. This will show all items from a wishlist.

Version 2.1

Changed the amount of widgets you can use from 9 to unlimited.

Version 2.0.1

Bugfix: Problem with widget header.

Version 2.0

Compatibility changed to WordPress 2.5 and higher.

RFC: Added shortcode implementation.

Number of items to be displayed in the widget can now be changed per widget.

Version 1.5

Bugfix: Old WSDL was used to look up the Wish List

RFC: Added Amazon.co.uk compatibility.

Version 1.4

Bugfix: Only 10 Items from a Wish List were loaded to setup the widget. All items are loaded now.

Bugfix: When the list contains one item the widget wouldn’t process it correctly (No image and wrong link).

RFC: Added Amazon.de compatibility.

RFC: Multiple items from the same Wish List can be displayed in the widget.

RFC: A configurable footer can be displayed on the bottom of the widget linking to the list on Amazon.

Updated WSDL Location.

Code improvements.

Version 1.3

RFC: Added Amazon.ca compatibility.

Version 1.2

Bug Fix: Creation of the link for the Wish List.

Version 1.1

Link from widget makes Amazon recognize it as a link from a Wish List. And the shipping address from the Wish List can be used.

Several bug fixes of files not found for WordPress 2.3.

Code clean up.

Version 1.0.1

Bug Fix: Don’t display purchased items from the lists.

Bug Fix: HTML problem when using WordPress 2.3

Version 1.0

Added compatibility with WordPress 2.5

Added option to use multiple widgets.

Version 0.4.1

Bug Fix: Didn’t display picture anymore

Version 0.4

Added an “tools” option under Admin -> Manage. You can look up your Wishlist ID by entering the email you use at Amazon. There is no check if the email is valid, if it isn’t you won’t see your wishlist(s)

”
Warning: Call-time pass-by-reference has been deprecated; If you would like to pass it by reference, modify the declaration of avh_get_list_results(). If you would like to enable call-time pass-by-reference, you can set allow_call_time_pass_reference to true in your INI file in / W E B P A T H /wp-content/plugins/avh-amazon/2.5/inc/avh-amazon.widgets.php on line 91

Warning: fopen(/home/germwork/public_html/blog/wp-content/plugins/avh-amazon/cache//wsdlcache-8d089f838d34c5d105c3f4b72f5e1e2a.lock) [function.fopen]: failed to open stream: Permission denied in /home/germwork/public_html/blog/wp-content/plugins/avh-amazon/inc/nusoap/class.wsdlcache.php on line 129

Warning: flock(): supplied argument is not a valid stream resource in /home/germwork/public_html/blog/wp-content/plugins/avh-amazon/inc/nusoap/class.wsdlcache.php on line 131

Jamison Fitzgerald

Works great for one widget, i even customized the css to remove the box surrounding the images and configured it to leave out the titles and put the items on one row to conserve space, however when i add a second widget and save everything it just copies the contents of the first widget, even if i go back and change it back as soon as i save it will fill the contents of all the options to be the same.

Hi – I have a funny problem… the widget won’t “stick” when I try to add it to the sidebar. I add it, click “save changes”, and when the page reloads… poof! It’s back on the left side again. I’m puzzled… I’ve never had a widget refuse to live in my sidebar before!

It seems the failure is related to the link Amazon provides the AVH Amazon plugin. We have discovered that short links fail. The short links are the sinple direct Amazon links with http://www.amazon.com and ending with the ASIN. The more complex links do not. These are the amazon links with extra tracking information between the ASIN and the Associate ID &tag.

We have been able to figure out that letting the short link fail at Amazon’s site and then manually inserting a ? or a / after the ASIN and just before &tag=[Associate ID] will cause the link to continue properly to the the related product; however, we do not know if Amazon is properly tracking this. Plus, we don’t know where to manually change AVH’s code to fix the problem.

Letting the short link fail at Amazon’s site and then manually inserting a ? or a / after the ASIN and just before &tag=[Associate ID] will cause the link to continue properly the the related product; however, we do not know if Amazon is properly tracking the manual fixes, plus we don’t know where to manually change AVH’s code to fix the problem.

Thanks for this wedding gift plugin. We are an event florist in Napa Valley and we are seeing many of our client use websites to help organize and remember their weddings. We will definitely pass this link on to our wedding flower customers.

Yes it will work with multiple authors but, and I think your real question is if each author can have their own associate ID. There can only be one associate id for the entire blog.

If you want an associate ID per author let me know and I’ll see what I can do.

mariella

Hello Peter, thank you very much for this great plugin. I would also be very interested to know if there is a possibility for each author to have his/her own associate ID. Are there more info available about that yet?
Thanks a lot

Anonymous

Could You please tell me if it’s working with Amazon.de? Thanks in advance.

I opened a topic on my Support Forum, if the suggestion below doesn’t work, let’s continue the discussion there.
On the page where you got your secret key, you can regenerate your secret key. Use this key for the plugin.

We have several different sites. Each have their own AWS Keys; therefore, resetting the keys at Amazon did not work.

3.0.3 worked fine with the AWS keys. 3.0.4 did not. Something in the new code is causing the error. Peter, perhaps you can try using Query Calls instead of REST Calls to get the XML data. This may hep you find the error.

Hi there, great plugin, I have one problem, the shortcode does not open links in a new window. I have set that option in the admin options of AVH and I tried hacking some of your code pages but cannot get it to open links in _blank ???

Stephane

Excellent add-on! The only feature I would like to see included is an easy way to center the books in the widgets.

Awesome plugin Peter, but no matter how i select to display the items in the sidebar widget, it still sorts them by most recently added. Is this a bug or does it take xx amount of hours to refresh the sort method?