[amazon_auto_links id="123"] <?php AmazonAutoLinks( array( 'id' => 123 ) ); ?>
label – the label associated with the units
[amazon_auto_links label="WordPress"] <?php AmazonAutoLinks( array( 'label' => 'WordPress' ) ); ?>
asin – ASINs (product IDs) separated by commas (`,`).
[amazon_auto_links asin="B016ZNRC0Q, B00ZV9PXP2"] <?php AmazonAutoLinks( array( 'asin' => 'B016ZNRC0Q, B00ZV9PXP2' ) ); ?>
search – Search keywords separated by commas (`,`).
[amazon_auto_links search="WordPress"] <?php AmazonAutoLinks( array( 'search' => 'WordPress' ) ); ?>
search arguments cannot be used together.
Optionally, the following arguments may be set.
country– (string) the locale of the store. Accepted values are
associate_id– (string) the Amazon Associates ID for the affiliate.
count– (integer) determines how many items should be displayed.
image_size– (integer) the image size in pixels.
title_length– (integer) the maximum title character length. Set
-1for no limit. Default:
description_length– (integer) the maximum description character length. Set
-1for no limit. Default:
link_style– (integer) the link style. Accepted values are
credit_link– (integer|boolean) whether to show the credit link.
subimage_size– (integer) the sub-image size in pixels. Default:
subimage_max_count– (integer) the maximum number of sub-images to display.
similar_product_image_size– (integer) the image size of similar products in pixels. Default:
similar_product_max_count– (integer) the maximum number of similar products.
customer_review_max_count– (integer) the maximum number of customer reviews.
show_now_retrieving_message– (boolean|integer) Whether to show the “Now retrieving…” message when sub-elements are pending to be fetched.
button_type– (integer) The type of buttons. The following values are accepted. Default:
0– Link to the product page.
1– Add to cart.
These values can be pre-defined from the setting page via
Amazon Auto Links ->
If these arguments are omitted, the values set in the setting page will be used.
HOW TO CREATE OWN TEMPLATE
Copy an existing template that is located in
...wp-content/plugins/amazon-auto-links/template and rename the copied folder.
Remove the files besides
template.php as other files are optional.
template.php to customize the layout.
Create a folder named
amazon-auto-links in your theme’s folder. If you are using Twenty Thirteen, the location would be
Move the working folder(the copied one) to it (the
amazon-auto-linksfolder you just created).
The plugin will automatically detect your template and add it in the template listing table. So activate it.
UPGRADING V1 TO V2
When upgrading v1 to v2, a few options will be lost. That includes:
- Sidebar widget
- The positions of the inserting area
These options need to be reconfigured.
HOW TO OBTAIN ACCESS KEY AND SECRET KEY
For the search unit type, an access key and its secret key are required to perform API requests.
We need to deal with additional two separate Amazon services apart from the Amazon Associates.
Step 1 – Create a Product Advertising API Account
Before you create an access key, you have to make sure you have singed up with Amazon Product Advertising API.
Step 2 – Sign up with Amazon Web Service
Next, create an account with Amazon Web Service(http://aws.amazon.com/). At the top right pull-down menu, you can navigate to
My Account/Console ->
Step 3 – Create an Access Key
In the Security Credentials page, find the section named
Access Keys (Access Key ID and Secret Access Key) and click on that.
Then press the
Create New Access Key button to create a key. Don’t forget to keep the secret access key as well. Amazon has changed the policy not to let the user to obtain the secret key later on.
Also note that at the point that an access key is issued, if you have not created an account with Product Advertising API, the key will be invalid. If that happens, delete the created access key and go back to the previous step.
You can check if your access key is valid or not with Scratchpad.
- Installation Instructions
- Do I need Amazon Associate ID to use this plug-in?
- Do I need Amazon Access Keys?
- What does Unit mean?
- What would be the benefit to upgrade to the pro version?
- I get a blank white page after adding a unit to the theme. What is it? What should I do?
- I have a feature request. Would you implement that?
- My credentials do not seem to be authenticated. How can I check if my access keys are the correct ones?