Viewing 9 replies - 1 through 9 (of 9 total)
  • Hi Peter,

    Thank you for your feedback.

    That is kind of a weird warning, considering the fact that on the line 87 there is no foreach loop.

    Please try to install AAM Utilities extension and clear all settings. This might help you to avoid the second warning.

    Keep us updated.
    Regards,
    Vasyl

    Thread Starter Peter Hardy-vanDoorn

    (@petervandoorn)

    I had thought to try the Utilities extension, but unfortunately the 2 errors completely break all AAM functionality, so the Download button doesn’t work!

    I have also already tried deleting the plugin files and reinstalling via FTP, but I don’t really want to try deleting it through WP as I don’t really want to delete the extensive user role settings!

    Hi Peter,

    As a quick fix, you might try to go to database and remove the option aam-extension-list in your wp_options table.

    The permanent fix is coming with our new release AAM 3.0.4 in couple days.

    Thank you for your feedback and let me know if this works for you.
    Regards,
    Vasyl

    Hi Vasyl,

    Was this problem resolved? I’m running 3.0.9 and get the same warning:
    Warning: Invalid argument supplied for foreach() in ../wp-content/plugins/advanced-access-manager/Application/Backend/Manager.php on line 87.

    Warning: Invalid argument supplied for foreach() in ../wp-content/plugins/advanced-access-manager/Application/Backend/Extension.php on line 180

    When visiting the AAM page in the admin I also get three alert pop-ups, all with the same warning:
    DataTables warning: table id=role-list - Invalid JSON response. For more information about this error, please see http://datatables.net/tn/1

    Opening the extension tab, there one more warning:
    Warning: Invalid argument supplied for foreach() in ../wp-content/plugins/advanced-access-manager/Application/Core/Repository.php on line 224

    Hi Studiobovenkamer,

    Please install WP Error Fix plugin so we can catch all your errors and provide fixes until the next AAM release is ready to go.

    Thank you,
    Vasyl

    Hi
    Same issue :/ It seems to break media manager too :s

    Thanks a lot for the futur fix πŸ™‚

    JC

    Hi All. Had the same problem but solved.
    (Backup files before editing)

    For error:
    1)
    Warning: Invalid argument supplied for foreach() in /…/wp-content/plugins/advanced-access-manager/Application/Backend/Manager.php on line 87

    Solution:
    In line 87 change
    “foreach($list as $extension)” to “foreach((array)$list as $extension)”

    2)
    Warning: Invalid argument supplied for foreach() in /…/wp-content/plugins/advanced-access-manager/Application/Core/Repository.php on line 224

    Solution:
    In line 224 change
    “foreach ($list as $row)” to “foreach ((array)$list as $row)”

    3)
    Warning: Invalid argument supplied for foreach() in /…/wp-content/plugins/advanced-access-manager/Application/Backend/Extension.php on line 180

    Solution:
    In line 180 change
    “foreach($list as $extension)” to “foreach((array)$list as $extension)”

    That works for me.
    Regards

    Hi guys,

    Sorry for the delay. We were overloaded here with some other stuff. This issue will be resolved today. I’ll personally will make sure that it will.

    Meantime please give a try to WP Error Fix plugin. This will allow us to get notified about PHP errors related to AAM.

    Thank you,
    Vasyl

    Hi,

    I have the same problem . After an updated I’ve received the same message :Warning: Invalid argument supplied for foreach() in /home3/geleto001/public_html/wp-content/plugins/post-grid/grid-items/variables.php on line 87

    It seems that the discussion is but the problem appears again . Can you give me some advice how to resolve that issue . I’ve wanted to try the Dawid_W’s solution but didn’t found the “foreach($list as $extension)” , so I can’t change it .

    Thanks in advance ,

Viewing 9 replies - 1 through 9 (of 9 total)

The topic ‘Invalid argument supplied for foreach() errors’ is closed to new replies.