Support » Plugin: Amazon Product in a Post Plugin » Warning: Invalid argument supplied for foreach()

Viewing 7 replies - 1 through 7 (of 7 total)
  • I am also getting this error.
    Using WP 3.6.1 and version 3.5.2 of the plugin.
    Using the Genesis framework, version 2.0.1, and it’s an HTML5 theme.

    Getting the error on both localhost (XAMPP), and KnownHost VPS.

    Follow Up:

    The problem was the AWS key and secret key I was given to use by the client were incorrect. Once I got the correct keys, it works perfectly.

    Very nice plugin. Love the amazon-elements shortcode. It adds a great deal of flexibility on what can be retrieved by the API.

    The only wish list for me is adding a search tool by keyword(s), and another by ASIN. Keyword search could bring up a list of products, and then the product could be viewed on Amazon, or selected to insert into the post/page.
    Just an idea… 🙂

    Thank you for your work on this plugin!

    I am also having this problem, I guess this is very common, If you try searching on google (excluding “”): “Warning: Invalid argument supplied foreach() in /inc/amazon-product-in-a-post-shortcodes.php on line 224” a lot of sites will show up. I have tried switching to curl and momentarily fixed the problem but it randomly reappears for a time then disappears again. Help anyone? 🙂

    More detailed info:
    – I am only using the new-price element.
    – This only happens when the price is not showing.
    – Only displays this error on the mainloop since it is included on the excerpt.
    – On the product page no price and no error are displayed.
    – breaks the site’s navigation when it happens parse error is displayed.

    On mine it looks like this has something to do with request throttling from Amazon’s API. If I right click on the error and inspect element it shows this hidden message:

    <!– APPIP ERROR:nodata[<!– HIDDEN APIP ERROR: RequestThrottled: Request from A3E915KZASEHUZ is throttled.–>

    I’m not a programmer. Could someone point me in the right direction on resources to maybe call the info once per day and then store the results without using Amazon’s API for every request?

    Hello, nice plugin 🙂
    But I’ve got the same problem here and same error:

    Warning: Invalid argument supplied for foreach()

    it happens when using the two types of shortcodes in your notice
    thanks for your help

    Got the same error, bot only with 10-20% of the products.
    All of the product are from the same category (in my case kindle books), but 10-20% doesn’t display, they only show this error:

    Warning: Invalid argument supplied for foreach() in /kunden/381825_1100/webseiten/kindofbook/wp-content/plugins/amazon-product-in-a-post-plugin/inc/amazon-product-in-a-post-shortcodes.php on line 224

    Here’s an example product that doesn’t work for me:

    Hope you can help quick!

    Thank you

Viewing 7 replies - 1 through 7 (of 7 total)
  • The topic ‘Warning: Invalid argument supplied for foreach()’ is closed to new replies.