diff --git a/modules/geolocation_googlemaps/geolocation_googlemaps.module b/modules/geolocation_googlemaps/geolocation_googlemaps.module
index 4e859f1..809fdf6 100644
--- a/modules/geolocation_googlemaps/geolocation_googlemaps.module
+++ b/modules/geolocation_googlemaps/geolocation_googlemaps.module
@@ -588,7 +588,9 @@ function geolocation_googlemaps_field_widget_form_alter(&$element, &$form_state,
 function geolocation_googlemaps_attach_google_js(&$element) {
   $js_added_already = &drupal_static(__FUNCTION__, FALSE);
   if (!$js_added_already) {
-    $data = [];
+    $data = array(
+      'callback' => 'initMap',
+    );
     $api_key = variable_get('geolocation_googlemaps_api_key', '');
     if (!empty($api_key)) {
       $data['key'] = $api_key;
diff --git a/modules/geolocation_googlemaps/geolocation_googlemaps_dynamic_formatter.js b/modules/geolocation_googlemaps/geolocation_googlemaps_dynamic_formatter.js
index c21fbc4..4807c26 100644
--- a/modules/geolocation_googlemaps/geolocation_googlemaps_dynamic_formatter.js
+++ b/modules/geolocation_googlemaps/geolocation_googlemaps_dynamic_formatter.js
@@ -6,7 +6,11 @@
  */
 
 (function($) {
+  var google_is_loaded = false;
 
+  window['initMap'] = function() {
+    google_is_loaded = true;
+  };
   Drupal.geolocationGooglemaps = Drupal.geolocationGooglemaps || {};
   Drupal.geolocationGooglemaps.maps = Drupal.geolocationGooglemaps.maps || {};
   Drupal.geolocationGooglemaps.markers = Drupal.geolocationGooglemaps.markers || {};
@@ -14,7 +18,13 @@
   Drupal.behaviors.geolocationGooglemapsDynamicFormatter = {
 
     attach : function(context, settings) {
+      if (!google_is_loaded) {
+        setTimeout($.proxy(function () {
+          this.attach.call(this, context, settings);
+        }, this), 100);
 
+        return;
+      }
       var fields = Drupal.settings.geolocationGooglemaps.formatters;
 
       // Work on each map
@@ -75,3 +85,4 @@
     }
   };
 }(jQuery));
+
diff --git a/modules/geolocation_googlemaps/geolocation_googlemaps_widget.js b/modules/geolocation_googlemaps/geolocation_googlemaps_widget.js
index fac2b83..8069529 100644
--- a/modules/geolocation_googlemaps/geolocation_googlemaps_widget.js
+++ b/modules/geolocation_googlemaps/geolocation_googlemaps_widget.js
@@ -4,11 +4,16 @@
  */
 
 (function ($) {
-  var geocoder;
+  var geocoder,
+      google_is_loaded = false;
   Drupal.geolocation = Drupal.geolocation || {};
   Drupal.geolocation.maps = Drupal.geolocation.maps || {};
   Drupal.geolocation.markers = Drupal.geolocation.markers || {};
 
+  window['initMap'] = function() {
+    google_is_loaded = true;
+  };
+
   /**
    * Set the latitude and longitude values to the input fields
    * And optionaly update the address field
@@ -201,6 +206,14 @@
 
   Drupal.behaviors.geolocationGooglemaps = {
     attach: function(context, settings) {
+      if (!google_is_loaded) {
+        setTimeout($.proxy(function () {
+          this.attach.call(this, context, settings);
+        }, this), 100);
+
+        return;
+      }
+
       geocoder = new google.maps.Geocoder();
 
       var lat;
@@ -323,3 +336,4 @@
     }
   };
 })(jQuery);
+
