Can you provide a link to your site so I can see what’s going on?
Do you have any plugins that deal with Javascript or CSS minification? Or plugins that try to manage the scripts of other plugins (like Plugin Organizer)?
Matt, I just turned off ALL plugins except yours on the jviation.com site. Still shows error at top of page:
Warning: Invalid argument supplied for foreach()
OK, can you email me that theme at support at wordimpress.com
Matt, Ted sent you the theme a couple of hours ago. We tried five other themes on our dev site, and we get the same error. Themes are:
Enigma, Orangi, Formation, Virtue, and Albar. These are unmodified themes directly from WordPress. Thanks.
I rolled Google Maps Builder back to 1.0.2 on the site for now. That version appears to be working and is not throwing an error. I also have all of the plugins enabled again, including Plugin Organizer 5.7.6.
Thanks.
I see the same problem.
The latest version of the plugin causes this error sometimes on a wordpress site.
“Warning: Invalid argument supplied for foreach() in /websites/la/laregotool.com.au/r764abq/wp-content/plugins/google-maps-builder/public/class-wordpress-google-maps.php on line 537”
This did not occur on the previous version and started as soon as the new version was activated.
Any fix available yet?
Using wordpress 4.1.
thanks
Barry
Hey the fix is coming in the next release but for now you can add:
if ( ! isset( $wp_scripts->registered ) ) {
return false;
}
above line 537 in public/class-wordpress-google-maps.php to fix the issue
Hi,
I just updated to the new Google Maps plugin and was getting this same error. I added the “fix” to public/class-wordpress-google-maps.php saved it and now am getting this error
“Parse error: syntax error, unexpected ‘public’ (T_PUBLIC) in /home/rebgro4/beccagrogan.com/wp-content/plugins/google-maps-builder/public/class-wordpress-google-maps.php on line 320”
I can’t even log in to my WordPress to delete the plugin or make changes. It just shows this and nothing else.
I tried to install this plugin now and also got an error:
Fatal error: Call to undefined function cmb_get_option() in C:\xampp\apps\wordpress\htdocs\wp-content\plugins\google-maps-builder\admin\class-wordpress-google-maps-settings.php on line 422
I cannot even uninstall the plugin from wordpress or log in to my site.
What’s happening and what should I do?
You can remove that plugin manually – using FTP or Cpanel, find it here and delete it:
wp-content
plugins
google-maps-builder - DELETE THIS FOLDER
Thanks WP Yogi – we’ll hotfix this today. Never want any Fatal errors.!
So even with the above “fix” I still get the error.
Warning: Invalid argument supplied for foreach() in [site]/wp-content/plugins/google-maps-builder/public/class-wordpress-google-maps.php on line 537
public function check_for_multiple_google_maps_api_calls() {
global $wp_scripts;
$multiple_google_maps_api = false;
if ( ! isset( $wp_scripts->registered ) ) {
return false;
}
//loop through registered scripts
foreach ( $wp_scripts->registered as $registered_script ) {
Would appreciate some help, or at least a time frame of when a fix will be available. I can’t run a site with a horrid looking error message on it.
Thanks for any help.