WordPress.org

Ready to get started?Download WordPress

Forums

[resolved] Warning: Invalid argument supplied for foreach() in /home/site/public_html/xx/wp (22 posts)

  1. allvisualweb
    Member
    Posted 2 years ago #

    Please, I want to remove this error message in the administrator

  2. esmi
    Forum Moderator
    Posted 2 years ago #

    Have you tried:

    - deactivating all plugins to see if this resolves the problem. If this works, re-activate the plugins one by one until you find the problematic plugin(s).

    - switching to the Twenty Eleven theme to rule out any theme-specific problems.

    - resetting the plugins folder by FTP or PhpMyAdmin. Sometimes, an apparently inactive plugin can still cause problems.

  3. allvisualweb
    Member
    Posted 2 years ago #

    Could I just disable the error message?

  4. esmi
    Forum Moderator
    Posted 2 years ago #

    You really need to find & fix the root cause.

  5. allvisualweb
    Member
    Posted 2 years ago #

    1 - deactivating all plugins
    2 - switching to the Twenty Eleven
    3 - deleted plugins folder

    It continues with the error

  6. allvisualweb
    Member
    Posted 2 years ago #

    error: /wp-admin/includes/plugin.php on line 1285

  7. esmi
    Forum Moderator
    Posted 2 years ago #

    Can we see the full error message please?

  8. allvisualweb
    Member
    Posted 2 years ago #

    Warning: Invalid argument supplied for foreach() in /home/virziona/public_html/wp-admin/includes/plugin.php on line 1285

    Warning: Invalid argument supplied for foreach() in /home/virziona/public_html/wp-admin/includes/plugin.php on line 1285

    Warning: Invalid argument supplied for foreach() in /home/virziona/public_html/wp-admin/includes/plugin.php on line 1285

  9. esmi
    Forum Moderator
    Posted 2 years ago #

    Site url?

  10. allvisualweb
    Member
    Posted 2 years ago #

    http://virzionair.com/somos-multiplos/

    It only appears in the admin menu. I see it when I try to add a widget, change a setting, work with menus, or update meta data for a post. It pops up all over the admin menu.

    Here is the function triggering the error in includes/plugin.php

  11. esmi
    Forum Moderator
    Posted 2 years ago #

    Can we see the site using Twenty Eleven with all plugins deactivated?

  12. allvisualweb
    Member
    Posted 2 years ago #

    Indeed, switching to the Twenty Eleven and the error did not show, and now?

  13. allvisualweb
    Member
    Posted 2 years ago #

    Thanks, theme reinstalled and it worked

  14. esmi
    Forum Moderator
    Posted 2 years ago #

    Excellent! :-)

  15. Jay
    Member
    Posted 1 year ago #

    Ran across this same issue and found this, Hopefully it will help others out if needed.

  16. AskPHPHosting
    Member
    Posted 1 year ago #

    Go to edit Theme Functons functions.php (your theme/functions.php) and remove something like that

    function my_remove_menu_pages() {
    	remove_menu_page('link-manager.php');
    	remove_menu_page('edit.php?post_type=portfolio');
    }
    add_action( 'admin_init', 'my_remove_menu_pages' );

    Its mean remove menu page not work with remove sub menu in admin area.

  17. brasofilo
    Member
    Posted 1 year ago #

    Re: admin_init

    I just run into this issue. The init is also called when doing Ajax, to remove menu pages the hook has to be: admin_menu.

    Check this comment: http://wordpress.org/support/topic/plugin-posts-2-posts-infinite-search-wheel?replies=7#post-1917503

  18. Webassertive
    Member
    Posted 1 year ago #

    I had the same issue. Resolved my issue by saving a design change and refreshing. I changed the home page from blog to static page but never changed the layout of the static page so I got the error. Went back and saved the layout, hit refresh and fixed.

  19. back8484
    Member
    Posted 1 year ago #

    My Fresh panel won't work in the new theme I download
    and it gives me an error message

    Warning: Invalid argument supplied for foreach() in /hermes/bosweb25a/b354/sl.redcolac/public_html/website/wp-content/themes/londoncreative copy/freshwork/freshpanel/freshpanel.php on line 9

    Can someone please help me?
    I have changed to the twenty eleveen theme and deactive all my plugins and nothing has changed after I switched back

  20. esmi
    Forum Moderator
    Posted 1 year ago #

    Where did you download this theme from?

  21. back8484
    Member
    Posted 1 year ago #

    from themeforest.net
    the theme is called the LONDON CREATIVE 4.3

  22. esmi
    Forum Moderator
    Posted 1 year ago #

    I'm sorry but as you are using a commercial theme, you need to seek support from the theme's developer/vendor. We do not support commercial themes here.

Topic Closed

This topic has been closed to new replies.

About this Topic