conditions

Placeholders

This is a list of all currently supported placeholders you can use in the template files.

 

Placeholder Description
{$ASIN} The ASIN code
{$SmallImageUrl} URL of the small product image
{$SmallImageWidth} The width of the small image
{$SmallImageHeight} The height of the small image
{$MediumImageUrl} URL of the medium product image
{$MediumImageWidth} The width of the medium image
{$MediumImageHeight} The height of the medium image
{$LargeImageUrl} URL of the large product image
{$LargeImageWidth} The width of the large image
{$LargeImageHeight} The height of the large image
{$Label} The product label, like “Walt Disney Pictures“
{$Manufacturer} The product manufacturer, like “Walt Disney Pictures“
{$Publisher} The product publisher, like “Walt Disney Pictures“
{$Studio} The product studio, like “Walt Disney Pictures“
{$Title} Product title
{$AmazonUrl} URL to the Amazon shop page of the product including your tracking ID
{$TotalOffers} The number of total offers
{$LowestOfferPrice} The lowest offer price without currency
{$LowestOfferCurrency} The lowest offer currency without price
{$LowestOfferFormattedPrice} The lowest offer price with currency
{$LowestNewOfferFormattedPrice} The lowest new offer price with currency
{$LowestUsedOfferFormattedPrice} The lowest used offer price with currency
{$AmazonPrice} The Amazon price without currency
{$AmazonPriceFormatted} The Amazon price with currency. This should be used as the major price placeholder.
{$ListPriceFormatted} The list price with currency
{$AmazonCurrency} The Amazon currency without price
{$AmazonAvailability} The product’s availability
{$AmazonLogoSmallUrl} URL of the small Amazon logo
{$AmazonLogoLargeUrl} URL of the large Amazon logo
{$DetailPageURL} URL to the product detail page
{$Platform} The product platform, like “PlayStation 3“ or “Windows“
{$ISBN} The product ISBN for books
{$EAN} The product EAN, like 0886974469926
{$NumberOfPages} The number of pages, usually empty
{$ReleaseDate} The release date of the product
{$Binding} The product binding, e.g. MP3-Download or Blu-ray
{$Author} The author of a book
{$Creator} The product creator, like for MP3-Downloads “Roy Orbison“ (the artist)
{$Edition} The product edition
{$AverageRating} The average customer rating in number, like 4.2
{$TotalReviews} The number of total reviews
{$RatingStars} The rating stars images
{$RatingStarsSrc} URL to the rating stars image file
{$Director} The director of a movie
{$Actors} The actors of a movie
{$RunningTime} The running time of a movie in minutes
{$Format} The product format, like “CD“ for a Blu-ray:
AC-3, Closed-captioned, Color, Dolby, DTS Surround Sound, Dubbed, Special Edition, Subtitled, Widescreen
{$CustomRating} Could be used to place your own rating in the
{$ProductDescription} The product description
{$AmazonDescription} The product description by Amazon
{$Artist} The product artist, like for music CDs “Adele“
{$Comment} Your own comment. You can write a comment directly into the [asa]-tag:
[asa comment="Hello world"]ASIN[/asa]
{$PercentageSaved} The percentage saved compared to the list price
{$Model} The product model, like “PC 151“
{$IFrameURL} Link to the user reviews page
{$Prime} Shows “AmazonPrime” if product is prime
{$PrimePic} Shows prime icon if product is prime

This post is also available in: German

46 thoughts on “Placeholders

  1. Hi mate,

    Loving your plugin so far. I am having a slight issue, I’m using the percentage saved place holder. On one or two products it doesn’t seem to pull the data and I’m not sure why. I’ve checked the product on amazon and there is the discount percentage on the product so I’m not sure what could be causing it.

    If you have any suggestions that would be great!

    Thanks,
    Adam

      • Sure mate,

        B001CBWAU4, B00132DLVE and I’m using the UK country code. It’s a bit strange as the others ASIN I am using are working perfectly.

        Thanks for getting back to me.

  2. Hi! It’s a Very nice plugin!

    I tried to set, which, I have {$RatingStars} and {$AverageRating} and {$TotalReviews} did not work.(JP Locale / Ver. 0.9.10.2)

    Why do I fix this?

  3. Is anyone getting an additional closing tag in their source code. I’ve checked and double checked my templates and all paragraphs are opened and closed properly and there are no loose ends, but when I check the source code of my live page I get a load of errors and there is a tag placed near the end of the code – don’t know where it’s coming from.

    • Through trial and error I’ve got rid of the erroneous tag by removing all blank spaces and line breaks in my code. If the code just runs in one continuous line then it’s fine, if you add a line break or space you get an erroneous tag – very annoying.

      • Hi Evie,
        thanks for your feedback. Could you please send me your code which produced the errors. I want to check if I could improve the plugin’s behaviour to avoid the problems.

  4. Hi Timo,
    Your ASA is very flexible. But, I’m at a lost on where the tpl directory is. Can you guide me as I’m unsure if I have installed the plugin completely?
    thank you.

    • Hi Con,
      thanks for your feedback. The tpl dir should be in (your-WP)/wp-content/plugins/amazonsimpleadmin/
      Where (your-WP) is your WP install root directory.

    • Hi Thierry,
      By default WordPress does not let you set a featured image from an external URL. And the plugin does not support an alternate method for that so far. I will add this suggestion to the feature request list.

    • Hi Moritz,
      thanks for your feedback. Manipulation the output of a placeholder is not supported with the current version. This feature is planned for the future. By now there is maybe a solution with CSS and a fixed width container or something like that…

  5. Is it possible to remove the ratings if there are no available?
    I think I must work with “if” and “else” in the template file but unfortunately I could not get it working.
    Can you help me?

    • Hi Tobi,
      thanks for your feedback.
      Conditions like if/else are supported in the current version but this feature is already planned and will come with one of the next updates.

  6. Hi there,
    This is a great plugin but I’m also having problems with the stray paragraph tag. It appears just after the last paragraph e.g. in the default template this would be the available sellers line.
    31 used & new available from £2.45

    • Hi Kate,
      could you send me an URL where I can see what you mean? Maybe I can help you customizing a template which betters fits to your theme.

  7. Hi Timo, I’m trying to get the plugin to work but it just won’t. I’ve already entered my Access Key info, and the “plugin status” shows “Ready”.

    However, when I try to use the shortcode in a post, or add items to a collection, the product information just shows up completely blank – no image, no price, no rating, just the ASIN number which I’ve entered.

    • Hi Kyle,
      thanks for your feedback. Did you set the country code to the store you are using? Empty information can happen if you eg use a ASIN from the US store but the plugin is set to the german store.
      You could activate the debugging mode in the setup panel temporarily, refresh your a page where the problems occur and send me the contents of the output.

  8. Hi Timo,
    many thanks for your great plugin – however, it can’t get the product description of books, or is there any way to fetch this info from amazon.de?
    Thanks!

    • Hi Ben,
      thanks for your feedback.
      For some products in some country’s stores there is no description. The Amazon API behaves differently from store to store. Which store and ASIN do you use in your case?

  9. Hi,
    is there any way to integrate the add to cart link into your plugin? e.g. to have the ASIN and my tracking ID automatically inserted in this code:

    any workaround?
    Thx

  10. Really love this plug-in, though I had to tweak AsaCore.php ever so slightly to make it support 3 more user-defined placeholders: “{$UsrArg1}”, “{$UsrArg2}”, and “{$UsrArg3}”. I need these in combination with customized tpl files.

    Here’s what I use them for:
    “{$UsrArg1}” – I pass an html “alt” tag value here. Without it all my amazon images would have an empty alt tag.

    “{$UsrArg2}” – Here I pass the pixel width of the image I want it scaled to.

    “{$UsrArg3}” – I don’t actually need a 3rd one yet, but I’m sure I’ll find a use for it eventually :)

    Here’s an example of how I call it:

    [asa photo, usrarg1="My Favorite", usrarg2="100"]B007B4THZI[/asa]

    It would be great if a future release of your plug-in formally supported user-defined arguments so I wouldn’t have to port my hack to future releases of it :)

    • Hi jennifer,
      thanks for your feedback. Including the customer reviews is not possible as Amazon does not provide the data. You can only link to the user review page with the placeholder {$IFrameURL}
      Similar products will be added to the wishlist ;-)

  11. Just working on implementing your plugin, really nice work!

    One question though: when using {$IFrameURL}, I noticed a parameter in the url like exp=….
    Does that mean that your cookie will expire at that time? Would be a good reason to set cache very low… (not good)
    So I think I prefer to work with Andreas’ workaround (see above), do you know if that’s good trackable code for Amazon?

    I don’t see the exp=… parameter when using {$AmazonUrl}
    Does that mean that I can safely use cache, and cookie expiration time will only start when the customer first clicks the link?
    Just to be sure…

    • Hi Oliver,
      the IFrameURL comes from Amazon completely. ASA does not change it. From the time of a request the IFrameURL is valid 24 hours, I think.
      The same for AmazonUrl. The plugin does not change the url delivered from Amazon.
      You can safely use the cache for AmazonUrl. If you want to cache IFrameURL, cache lifetime should not exceed 24 hours. But thats just what I think and I do not use the IFrameURL placeholder on any site.

  12. Pingback: Wordpress - AmazonSimpleAdmin - Rezensionen

Leave a Reply

Your email address will not be published. Required fields are marked *

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>

participate