Support » Plugin: Jetpack by » Invalid argument supplied for foreach() … on line 242

  • Resolved chermsen


    Hi there

    I have a new and clean installation. After activating Jetpack a warning appears on the right column

    Warning: Invalid argument supplied for foreach() in */wordpress/wp-content/plugins/jetpack/modules/widget-visibility/widget-conditions.php on line 242

    Tested with different Themes.

Viewing 10 replies - 1 through 10 (of 10 total)
  • Plugin Contributor Richard Archambault


    Which version of Jetpack are you using? Can you make sure you have 2.4.2? Also, could you post your site URL here, so I can have a look?

    If you want it to remain private, you can also contact us via this contact form:

    I just refreshed the page before making a screenshot and the warning disappeared without any action. Thats it. Sometimes just asking the right person solves the problem 😉

    Plugin Contributor Richard Archambault


    Awesome! Let me know if it pops up again, then. 🙂

    I get the exact same error, new and clean WP installation. I’ve also tested with different themes. I’m using Jetpack version 2.6.1.

    My URL is

    Plugin Author Jeremy Herve


    Could you try to delete the Jetpack and reinstall it from scratch?

    If that doesn’t help, could you try to deactivate all other plugins you may have installed on your site, one at a time, and let me know if you find a conflicting plugin?


    Hi Jeremy.

    Tried deactivating each of the other plug-ins until the only one active was Jetpack.
    Still got that error – and I tried deleting the plug-in and then re-installing just to get the exact same error.

    What should I try next?

    Plugin Author Jeremy Herve


    Could you go to Appearance > Widgets in your dashboard, and save all your Widget Visibility settings once again?

    Let me know if it helps.

    You know what.
    After having deactivating each of the plug-ins and having re-installed the Jetpak plug-in, I had no succes and still the same error.

    But today, when loggin in, the error was not there.
    Can’t really say why, sadly, but good this is that the error is no longer there.

    Have a nice evening.

    I installed the theme, love it. Went and changed the text for the sliders.
    Now all I get is the loading Icon. I do not see any errors in the apache log files.

    Really need to figure this on out. If you could help or suggest, I have full access to the server.


    Plugin Author Jeremy Herve


    @rodfoodhost Could you please start your own thread, as per the Forum Welcome?

    Thank you!

Viewing 10 replies - 1 through 10 (of 10 total)
  • The topic ‘Invalid argument supplied for foreach() … on line 242’ is closed to new replies.