Support » Plugins and Hacks » Amazon Product in a Post Plugin » Out of Stock where price should be

Out of Stock where price should be

Viewing 15 replies - 1 through 15 (of 25 total)
  • Plugin Author Don Fischer


    can you give me a link to an example please?

    The wordpress is not live as I’m just starting to build the site. Where new and use is there is an “Out of Stock” where the price should be listed.

    Is there a way to copy a or get a code that might help figure out what is wrong since it isn’t launched?

    Plugin Author Don Fischer


    You could tell me the locale you are using and the ASINs for the products you are having a problem with. The locale would be .com, .co.uk, etc.


    Hey Don,

    Sorry its taken a minute to get back to you. Two listed below say out of stock as well as others.

    This is the only one that seems to work

    Is there maybe a way to just display the price and override the “Out of Stock” information? Just thinking of alternatives if this is something that can’t be fixed.


    I would also like to mention the reason it may being do this is because there are different sizes to pick from.

    Why didn’t my reply show up here? I have the same problem. The only thing that shows up is the item image. Does anyone know how to fix this problem..

    Moderator Jan Dembowski


    Brute Squad and Volunteer Moderator

    Why didn’t my reply show up here?

    Spam filter. We get lots of spam on these forums.

    Hi, got mine to work when using shortcodes instead of using the “New amazon post” option.

    Try this shortcode: [AMAZONPRODUCTS asin=”B0084IG8TM” features=”0″ locale=”com”]

    Spoke too soon. Now it doesn’t work.. And trying to use a different Amazon buy it now button by using short code doesn’t work either. Tried so many different variations. About to call it a day with this plug-in.




    Experiencing the same problem for some items.

    Looking at the database table ‘amazoncache’ one can see that for these items the attributes information is not stored in the database. However according to aws_signed_request.php it does have the code to look up things.

    Then looked at the XML feed through the Product Advertising Scratch Pad (http://associates-amazon.s3.amazonaws.com/scratchpad/index.html) to see if the XML feed ResponseGroup ‘Attributes’ contained the info. The ‘Attributes’ in the original feed didn’t have the information either.

    The Responsegroup ‘Variations’ does have the information. This possibly to account for prize variations between different size and colors.

    From what I gather from aws_signed_request.php the ‘Variations’ Responsegroup needs to be also loaded for this change to work? That’s what I’ve been able to figure out so far, I could be wrong though?

    function GetAPPIPReturnValArray($Item,$Errors){
     	//processor function for product created by Don Fischer http://www.fischercreativemedia.com
        $ItemAttr 									= isset($Item['ItemAttributes']) ? $Item['ItemAttributes'] : array();
        $ItemOffSum 								= isset($Item['OfferSummary']) ? $Item['OfferSummary'] : array();
        $ItemOffers 								= isset($Item['Offers']) ? $Item['Offers'] : array();
        $ItemAmazOffers								= isset($Item['Offers']) ? $Item['Offers'] : array();
      	$ImageSM									= isset($Item['SmallImage']['URL']) ? $Item['SmallImage']['URL'] : '';
      	$ImageMD 									= isset($Item['MediumImage']['URL']) ? $Item['MediumImage']['URL'] : '';
      	$ImageLG 									= isset($Item['LargeImage']['URL']) ? $Item['LargeImage']['URL'] : '';
      	$ImageSets									= isset($Item['ImageSets']['ImageSet']) ? $Item['ImageSets']['ImageSet'] : '';
    	$DetailPageURL 								= isset($Item['DetailPageURL']) ? $Item['DetailPageURL'] : array();
        $ASIN 										= isset($Item['ASIN']) ? $Item['ASIN'] : array();
        $ItemRev									= isset($Item['CustomerReviews']) ? $Item['CustomerReviews'] : array();
    	$DescriptionAmz								= isset($Item["EditorialReviews"]["EditorialReview"]) ? $Item["EditorialReviews"]["EditorialReview"] : array();
    	$cached										= isset($Item["CachedAPPIP"]) ? $Item["CachedAPPIP"] : 0;

    Hope it helps somewhat in finding a resolution to this problem.



    Question if I may:

    Where (and how) is the ResponseGroup set? I can’t seem to find the variable to load it.

    Tried to add $Item[‘Variations’] to the function GetAPPIPReturnValArray in aws_signed_request.php to see if that would return the ResponseGroup ‘Variations’, however that gets me a NULL result. It will only return certain ResponseGroups such as ‘ItemAttributes’ within the function. All I get is ResponseGroup ‘Large’ when I do a var_dump in appip_get_XML_structure in aws_signed_request.php

    From what I read the ‘Large’ ResponseGroup shouldn’t be used though (and doesn’t contain the ‘Variations’ ResponseGroup, which could possibly explain why it can’t be called?):

    “The Large response group returns a great deal of information about items in the response. The Large response group is for demonstration purpose and is not suitable for production applications. Precise required response groups should always be used in applications to reduce latency and response size.”

    See response group ‘Large” in the AWS Documentation Product Advertising API on Response groups: http://docs.aws.amazon.com/AWSECommerceService/latest/DG/CHAP_ResponseGroupsList.html

    Plugin Author Don Fischer


    @design_dolphin & all –
    A few things:

    1. The documentation about the Large Response Group not being used in production because it is too large, is a bit out of date. Other response groups (like Variations for example) can return 3-4 times more data than the Large group.
    2. The reason we chose the Large Response group for the plugin is that there are a lot of elements that users want in the display – and the Large group has almost everything we need (except in those cases where variations may be present).
    3. We are working on the next release (still) but have it in testing now. It has the VariationSummary response group as part of the request. In the event, you need something else, there will be a filter that allows you to add to it.
    4. Lastly – if you are looking for the place where the response group is located, it is not in the aws_signed_request.php, but in the amazon-product-in-a-post-functions.php when the request happens (in the getSingleAmazonProduct function there is a variable called $appip_responsegroup).

    We do have the version available to test if you want to test it out:
    Version 3.5.3 beta.

    Hopefully this helps everyone out.
    Warm regards,



    It definitely helps me. Thank you.

    Testing the Beta version:

    In all below variations of $appip_responsegroup the list price and sale price are the same if the item is not on sale (needs an if the price is the same then don’t show?). If the item is on sale, the correct list and sale price shows. This through the ‘Amazon Product ASIN (ISBN-10)’ interface in the post screen.

    $appip_responsegroup 	= apply_filters('getSingleAmazonProduct_response_group',"Large,Reviews,VariationSummary");

    (in amazon-product-in-a-post-function.php)

    Didn’t give access to one of the variation responsegroups when added.
    When the Large Responsegroup is set it may override some of the Variations response groups?

    Changing it to:

    $appip_responsegroup            = apply_filters('getSingleAmazonProduct_response_group',"ItemAttributes,Images,VariationImages, VariationMatrix, VariationSummary");


    $appip_responsegroup            = apply_filters('getSingleAmazonProduct_response_group',"ItemAttributes,Images,Variations");

    Loaded the XML that I was looking for. I’m not sure if it works with (all) shortcodes, but I can work around that.

    If you need/ want some help in the future to flesh out the shortcodes for the variations feel free to contact me, and I’ll see what I can do.

    Plugin Author Don Fischer


    VariationSummary is just a summary of the variation pricing. If you add the Variations or others that you mention, you get all of the Variations (which is a LOT of data and adds additional response when calling the API). I would recommend just using the summary if you can. I would probably not add all the extra to the plugin because it is WAY more information than most users need and the added return time will slow down page loads a bit.

    That is why we added the filters – so a user could add them if they wanted to for their version. So you would do something like this in your functions.php file:

    function add_my_own_response_group($rgroups){
       return $rgroups.',VariationImages, VariationMatrix';

    As for accessing the variables – we added a new processing object function to this version that has all returned variables. This version makes use of a few items in this new array, but they will be used in the next version to replace the existing array and make the plugin more dynamic and filterable. If you look at line 88 of amazon-product-in-a-post-functions.php file, you can print out the new object and see all variables.

    We need to get this version out sooner than later because it fixes a few flaws in the 3.5.2 version and people are waiting for it. In the next version, we will address most of your concerns about the Variable pricing. Note that you CAN turn off the list price in both the shortcode and the single product (single product has a checkbox to remove the list price, shortcode has a variable). So when that is an issue, I would suggest just turning it off.

    AND one last thing that is worth noting for those who read this post and try to fix their version of the plugin using anything in this post – DO NOT MODIFY THE PLUGIN CODE AT ALL – if you do, when the plugin updates you WILL lose all modifications as it is overwritten. Always try to use filters and hooks in your functions.phptheme file (or child theme file is relevant) – it will save you a lot of time and frustration.

    Warm regards,

Viewing 15 replies - 1 through 15 (of 25 total)
  • The topic ‘Out of Stock where price should be’ is closed to new replies.
Skip to toolbar