WP Google Maps - Version 6.3.10

Version Description

  • 2016-05-03 - Low priority =
  • Added event listeners for both jQuery and accordions so that the map can init correctly when placed in a tab or accordion
  • Added checks to stop themes and plugins from loading the Google Maps API over and above our call to the API on pages that contain the map shortcode
  • Fixed an SSL issue with the marker URL (Thank you David Clough)
  • Fixed a bug that caused the CSS file to be loaded on all front end pages
  • Added SSL support to the jQuery CDN file
Download this release

Release Info

Developer WPGMaps
Plugin Icon 128x128 WP Google Maps
Version 6.3.10
Comparing to
See all releases

Code changes from version 6.3.09 to 6.3.10

cache/timthumb_cacheLastCleanTime.touch DELETED
File without changes
cache/timthumb_int_1feb94dfe4564036dfa309e87c1c70aa.timthumb.txt DELETED
Binary file
cache/timthumb_int_9b31d30bd2ddcfe0c062091cc5c498d7.timthumb.txt DELETED
Binary file
cache/wpgmaps.tmp DELETED
@@ -1 +0,0 @@
1
- Permission Check
 
readme.txt CHANGED
@@ -207,6 +207,13 @@ Please upgrade your version of WP Google Maps to version 6.0.27 as it includes m
207
 
208
  == Changelog ==
209
 
 
 
 
 
 
 
 
210
  = 6.3.09 - 2016-04-15 - High priority =
211
  * Deprecated google maps api 3.14 and 3.15, added 3.23 and 3.24
212
 
207
 
208
  == Changelog ==
209
 
210
+ = 6.3.10 - 2016-05-03 - Low priority =
211
+ * Added event listeners for both jQuery and accordions so that the map can init correctly when placed in a tab or accordion
212
+ * Added checks to stop themes and plugins from loading the Google Maps API over and above our call to the API on pages that contain the map shortcode
213
+ * Fixed an SSL issue with the marker URL (Thank you David Clough)
214
+ * Fixed a bug that caused the CSS file to be loaded on all front end pages
215
+ * Added SSL support to the jQuery CDN file
216
+
217
  = 6.3.09 - 2016-04-15 - High priority =
218
  * Deprecated google maps api 3.14 and 3.15, added 3.23 and 3.24
219
 
wpGoogleMaps.php CHANGED
@@ -3,7 +3,7 @@
3
  Plugin Name: WP Google Maps
4
  Plugin URI: http://www.wpgmaps.com
5
  Description: The easiest to use Google Maps plugin! Create custom Google Maps with high quality markers containing locations, descriptions, images and links. Add your customized map to your WordPress posts and/or pages quickly and easily with the supplied shortcode. No fuss.
6
- Version: 6.3.09
7
  Author: WP Google Maps
8
  Author URI: http://www.wpgmaps.com
9
  Text Domain: wp-google-maps
@@ -11,10 +11,17 @@ Domain Path: /languages
11
  */
12
 
13
  /*
 
 
 
 
 
 
 
 
14
  * 6.3.09 - 2016-04-15 - High priority
15
  * Deprecated google maps api 3.14 and 3.15, added 3.23 and 3.24
16
  *
17
- *
18
  * 6.3.08 - 2016-04-14 - Medium Priority
19
  * Provides a workaround for users experiencing issues with their maps loading after updating to WordPress 4.5
20
  *
@@ -227,8 +234,8 @@ $wpgmza_tblname_poly = $wpdb->prefix . "wpgmza_polygon";
227
  $wpgmza_tblname_polylines = $wpdb->prefix . "wpgmza_polylines";
228
  $wpgmza_tblname_categories = $wpdb->prefix. "wpgmza_categories";
229
  $wpgmza_tblname_category_maps = $wpdb->prefix. "wpgmza_category_maps";
230
- $wpgmza_version = "6.3.09";
231
- $wpgmza_p_version = "6.3.09";
232
  $wpgmza_t = "basic";
233
  define("WPGMAPS", $wpgmza_version);
234
  define("WPGMAPS_DIR",plugin_dir_url(__FILE__));
@@ -619,10 +626,16 @@ function wpgmaps_get_marker_url($mapid = false) {
619
 
620
  if (is_multisite()) {
621
  global $blog_id;
 
622
  $wurl = $xml_marker_url.$blog_id."-".$mapid."markers.xml";;
 
623
  }
624
  else {
625
  $wurl = $xml_marker_url.$mapid."markers.xml";
 
 
 
 
626
  }
627
  }
628
 
@@ -1654,7 +1667,7 @@ function wpgmaps_user_javascript_basic() {
1654
  if ('undefined' === typeof window.jQuery) {
1655
  setTimeout(function(){
1656
  document.getElementById('wpgmza_map').innerHTML = 'Error: In order for WP Google Maps to work, jQuery must be installed. A check was done and jQuery was not present. Please see the <a href="http://www.wpgmaps.com/documentation/troubleshooting/jquery-troubleshooting/" title="WP Google Maps - jQuery Troubleshooting">jQuery troubleshooting section of our site</a> for more information.';
1657
- }, 3000);
1658
  } else {
1659
  /* all good.. continue... */
1660
  }
@@ -1666,7 +1679,7 @@ function wpgmaps_user_javascript_basic() {
1666
  if (/1\.(0|1|2|3|4|5|6|7)\.(0|1|2|3|4|5|6|7|8|9)/.test(jQuery.fn.jquery)) {
1667
  setTimeout(function(){
1668
  document.getElementById('wpgmza_map').innerHTML = 'Error: Your version of jQuery is outdated. WP Google Maps requires jQuery version 1.7+ to function correctly. Go to Maps->Settings and check the box that allows you to over-ride your current jQuery to try eliminate this problem.';
1669
- }, 3000);
1670
  } else {
1671
 
1672
  jQuery("#wpgmza_map").css({
@@ -1683,6 +1696,16 @@ function wpgmaps_user_javascript_basic() {
1683
  UniqueCode=Math.round(Math.random()*10000);
1684
  MYMAP.placeMarkers('<?php echo wpgmaps_get_marker_url($wpgmza_current_map_id); ?>?u='+UniqueCode,<?php echo $wpgmza_current_map_id; ?>,null,null,null);
1685
  });
 
 
 
 
 
 
 
 
 
 
1686
 
1687
 
1688
  jQuery('body').on('click', '.wpb_tabs_nav li', function(event, ui) {
@@ -5564,8 +5587,11 @@ function wpgmaps_user_styles() {
5564
 
5565
  if (!function_exists('wpgmaps_admin_styles_pro')) {
5566
  global $wpgmza_version;
5567
- wp_register_style( 'wpgmaps-style', plugins_url('css/wpgmza_style.css', __FILE__),array(),$wpgmza_version);
5568
- wp_enqueue_style( 'wpgmaps-style' );
 
 
 
5569
  }
5570
 
5571
 
@@ -6203,7 +6229,7 @@ function wpgmaps_load_jquery() {
6203
  if (isset($wpgmza_settings['wpgmza_settings_force_jquery'])) {
6204
  if ($wpgmza_settings['wpgmza_settings_force_jquery'] == "yes") {
6205
  wp_deregister_script('jquery');
6206
- wp_register_script('jquery', 'http://code.jquery.com/jquery-1.11.3.min.js', false, "1.11.3");
6207
  }
6208
  }
6209
  wp_enqueue_script('jquery');
@@ -6382,3 +6408,27 @@ function wpgmza_basic_support_menu() {
6382
 
6383
  <?php
6384
  }
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
3
  Plugin Name: WP Google Maps
4
  Plugin URI: http://www.wpgmaps.com
5
  Description: The easiest to use Google Maps plugin! Create custom Google Maps with high quality markers containing locations, descriptions, images and links. Add your customized map to your WordPress posts and/or pages quickly and easily with the supplied shortcode. No fuss.
6
+ Version: 6.3.10
7
  Author: WP Google Maps
8
  Author URI: http://www.wpgmaps.com
9
  Text Domain: wp-google-maps
11
  */
12
 
13
  /*
14
+ * 6.3.10 - 2016-05-03 - Low priority
15
+ * Added event listeners for both jQuery and accordions so that the map can init correctly when placed in a tab or accordion
16
+ * Added checks to stop themes and plugins from loading the Google Maps API over and above our call to the API on pages that contain the map shortcode
17
+ * Fixed an SSL issue with the marker URL (Thank you David Clough)
18
+ * Fixed a bug that caused the CSS file to be loaded on all front end pages
19
+ * Added SSL support to the jQuery CDN file
20
+ *
21
+ *
22
  * 6.3.09 - 2016-04-15 - High priority
23
  * Deprecated google maps api 3.14 and 3.15, added 3.23 and 3.24
24
  *
 
25
  * 6.3.08 - 2016-04-14 - Medium Priority
26
  * Provides a workaround for users experiencing issues with their maps loading after updating to WordPress 4.5
27
  *
234
  $wpgmza_tblname_polylines = $wpdb->prefix . "wpgmza_polylines";
235
  $wpgmza_tblname_categories = $wpdb->prefix. "wpgmza_categories";
236
  $wpgmza_tblname_category_maps = $wpdb->prefix. "wpgmza_category_maps";
237
+ $wpgmza_version = "6.3.10";
238
+ $wpgmza_p_version = "6.3.10";
239
  $wpgmza_t = "basic";
240
  define("WPGMAPS", $wpgmza_version);
241
  define("WPGMAPS_DIR",plugin_dir_url(__FILE__));
626
 
627
  if (is_multisite()) {
628
  global $blog_id;
629
+
630
  $wurl = $xml_marker_url.$blog_id."-".$mapid."markers.xml";;
631
+ $wurl = preg_replace('#^https?:#', '', $wurl);
632
  }
633
  else {
634
  $wurl = $xml_marker_url.$mapid."markers.xml";
635
+ $wurl = preg_replace('#^https?:#', '', $wurl);
636
+
637
+
638
+
639
  }
640
  }
641
 
1667
  if ('undefined' === typeof window.jQuery) {
1668
  setTimeout(function(){
1669
  document.getElementById('wpgmza_map').innerHTML = 'Error: In order for WP Google Maps to work, jQuery must be installed. A check was done and jQuery was not present. Please see the <a href="http://www.wpgmaps.com/documentation/troubleshooting/jquery-troubleshooting/" title="WP Google Maps - jQuery Troubleshooting">jQuery troubleshooting section of our site</a> for more information.';
1670
+ }, 6000);
1671
  } else {
1672
  /* all good.. continue... */
1673
  }
1679
  if (/1\.(0|1|2|3|4|5|6|7)\.(0|1|2|3|4|5|6|7|8|9)/.test(jQuery.fn.jquery)) {
1680
  setTimeout(function(){
1681
  document.getElementById('wpgmza_map').innerHTML = 'Error: Your version of jQuery is outdated. WP Google Maps requires jQuery version 1.7+ to function correctly. Go to Maps->Settings and check the box that allows you to over-ride your current jQuery to try eliminate this problem.';
1682
+ }, 6000);
1683
  } else {
1684
 
1685
  jQuery("#wpgmza_map").css({
1696
  UniqueCode=Math.round(Math.random()*10000);
1697
  MYMAP.placeMarkers('<?php echo wpgmaps_get_marker_url($wpgmza_current_map_id); ?>?u='+UniqueCode,<?php echo $wpgmza_current_map_id; ?>,null,null,null);
1698
  });
1699
+ jQuery('body').on('tabsshow', function(event, ui) {
1700
+ MYMAP.init('#wpgmza_map', myLatLng, <?php echo $start_zoom; ?>);
1701
+ UniqueCode=Math.round(Math.random()*10000);
1702
+ MYMAP.placeMarkers('<?php echo wpgmaps_get_marker_url($wpgmza_current_map_id); ?>?u='+UniqueCode,<?php echo $wpgmza_current_map_id; ?>,null,null,null);
1703
+ });
1704
+ jQuery('body').on('accordionactivate', function(event, ui) {
1705
+ MYMAP.init('#wpgmza_map', myLatLng, <?php echo $start_zoom; ?>);
1706
+ UniqueCode=Math.round(Math.random()*10000);
1707
+ MYMAP.placeMarkers('<?php echo wpgmaps_get_marker_url($wpgmza_current_map_id); ?>?u='+UniqueCode,<?php echo $wpgmza_current_map_id; ?>,null,null,null);
1708
+ });
1709
 
1710
 
1711
  jQuery('body').on('click', '.wpb_tabs_nav li', function(event, ui) {
5587
 
5588
  if (!function_exists('wpgmaps_admin_styles_pro')) {
5589
  global $wpgmza_version;
5590
+ global $short_code_active;
5591
+ if ($short_code_active) {
5592
+ wp_register_style( 'wpgmaps-style', plugins_url('css/wpgmza_style.css', __FILE__),array(),$wpgmza_version);
5593
+ wp_enqueue_style( 'wpgmaps-style' );
5594
+ }
5595
  }
5596
 
5597
 
6229
  if (isset($wpgmza_settings['wpgmza_settings_force_jquery'])) {
6230
  if ($wpgmza_settings['wpgmza_settings_force_jquery'] == "yes") {
6231
  wp_deregister_script('jquery');
6232
+ wp_register_script('jquery', '//code.jquery.com/jquery-1.11.3.min.js', false, "1.11.3");
6233
  }
6234
  }
6235
  wp_enqueue_script('jquery');
6408
 
6409
  <?php
6410
  }
6411
+
6412
+
6413
+ add_action('wp_enqueue_scripts', 'wpgmza_deregister_scripts',999);
6414
+ add_action('wp_head', 'wpgmza_deregister_scripts',999);
6415
+ add_action('wp_footer', 'wpgmza_deregister_scripts',999);
6416
+ add_action('wp_print_scripts', 'wpgmza_deregister_scripts',999);
6417
+ function wpgmza_deregister_scripts() {
6418
+ global $short_code_active;
6419
+ if ($short_code_active) {
6420
+ /* only deregister on pages that contain the shortcode */
6421
+ wp_dequeue_script("google_map");
6422
+ wp_dequeue_script("google_map2");
6423
+ wp_dequeue_script("gmap-key");
6424
+ wp_dequeue_script("imic_google_map");
6425
+ wp_dequeue_script("googlemap");
6426
+ wp_dequeue_script("googlemaps");
6427
+ wp_dequeue_script("gmap_form_api");
6428
+ wp_dequeue_script("map-api");
6429
+ wp_dequeue_script("google-maps-v3");
6430
+ wp_dequeue_script("googlemaps-v3");
6431
+ wp_dequeue_script("googlemapsv3");
6432
+ }
6433
+
6434
+ }