Gantry 4 Framework - Version 4.1.8

Version Description

  • Fixed fallback to en_US language file if the localized .mo file doesn't exist
  • Fixed Fatal Error that could occur when WPML ICL_Language_Switcher class is missing
  • Changed display of plugin name to Gantry 4 Framework
Download this release

Release Info

Developer gantry
Plugin Icon 128x128 Gantry 4 Framework
Version 4.1.8
Comparing to
See all releases

Code changes from version 4.1.7 to 4.1.8

CHANGELOG.php CHANGED
@@ -2,7 +2,7 @@
2
  /**
3
  * Gantry For Wordpress
4
  *
5
- * @version $Id: CHANGELOG.php 61427 2015-08-02 10:28:08Z jakub $
6
  * @author RocketTheme http://www.rockettheme.com
7
  * @copyright Copyright (C) 2007 - 2015 RocketTheme, LLC
8
  * @license http://www.gnu.org/licenses/gpl-2.0.html GNU/GPLv2 only
@@ -27,6 +27,11 @@ Legend:
27
  - -> Removed
28
  ! -> Note
29
 
 
 
 
 
 
30
  ------- 4.1.7 Release [] ------
31
  ^ Updated FontAwesome to 4.4.0
32
 
2
  /**
3
  * Gantry For Wordpress
4
  *
5
+ * @version $Id: CHANGELOG.php 61601 2015-09-18 17:02:04Z jakub $
6
  * @author RocketTheme http://www.rockettheme.com
7
  * @copyright Copyright (C) 2007 - 2015 RocketTheme, LLC
8
  * @license http://www.gnu.org/licenses/gpl-2.0.html GNU/GPLv2 only
27
  - -> Removed
28
  ! -> Note
29
 
30
+ ------- 4.1.8 Release [] ------
31
+ # Fixed fallback to en_US language file if the localized .mo file doesn't exist
32
+ # Fixed Fatal Error that could occur when WPML ICL_Language_Switcher class is missing
33
+ ^ Changed display of plugin name to Gantry 4 Framework
34
+
35
  ------- 4.1.7 Release [] ------
36
  ^ Updated FontAwesome to 4.4.0
37
 
admin/forms/fields/imagepicker.php CHANGED
@@ -1,6 +1,6 @@
1
  <?php
2
  /**
3
- * @version 4.1.7 August 18, 2015
4
  * @author RocketTheme http://www.rockettheme.com
5
  * @copyright Copyright (C) 2007 - 2015 RocketTheme, LLC
6
  * @license http://www.gnu.org/licenses/gpl-2.0.html GNU/GPLv2 only
1
  <?php
2
  /**
3
+ * @version 4.1.8 September 18, 2015
4
  * @author RocketTheme http://www.rockettheme.com
5
  * @copyright Copyright (C) 2007 - 2015 RocketTheme, LLC
6
  * @license http://www.gnu.org/licenses/gpl-2.0.html GNU/GPLv2 only
admin/forms/fields/updater.php CHANGED
@@ -27,7 +27,7 @@ class GantryFormFieldUpdater extends GantryFormField
27
 
28
  $currentVersion = GANTRY_VERSION;
29
 
30
- if ($currentVersion == "\4.1.7") $currentVersion = "[DEV]";
31
 
32
  // curl check
33
  if (!function_exists('curl_version')) {
27
 
28
  $currentVersion = GANTRY_VERSION;
29
 
30
+ if ($currentVersion == "\4.1.8") $currentVersion = "[DEV]";
31
 
32
  // curl check
33
  if (!function_exists('curl_version')) {
admin/widgets/colorchooser/css/mooRainbow-2.0.css CHANGED
@@ -1,5 +1,5 @@
1
  /**
2
- * @version 4.1.7 August 18, 2015
3
  * @author RocketTheme http://www.rockettheme.com
4
  * @copyright Copyright (C) 2007 - 2015 RocketTheme, LLC
5
  * @license http://www.gnu.org/licenses/gpl-2.0.html GNU/GPLv2 only
1
  /**
2
+ * @version 4.1.8 September 18, 2015
3
  * @author RocketTheme http://www.rockettheme.com
4
  * @copyright Copyright (C) 2007 - 2015 RocketTheme, LLC
5
  * @license http://www.gnu.org/licenses/gpl-2.0.html GNU/GPLv2 only
core/gantry.class.php CHANGED
@@ -1056,7 +1056,7 @@ class Gantry
1056
  $path = '/' . preg_replace('#^' . quotemeta($this->baseUrl) . '#', "", $path);
1057
  }
1058
  $filename = strtolower(basename($path, '.css')) . rand(0, 1000);
1059
- wp_enqueue_style($filename, $path, array(), '4.1.7');
1060
  $deps[] = $path;
1061
  }
1062
  }
@@ -1069,11 +1069,11 @@ class Gantry
1069
  if ($this->baseUrl != "/") {
1070
  $path = '/' . preg_replace('#^' . quotemeta($this->baseUrl) . '#', "", $path);
1071
  }
1072
- wp_enqueue_script($path, $path, $deps, '4.1.7');
1073
  $deps[] = $path;
1074
  }
1075
  foreach ($this->_header_full_scripts as $strSrc) {
1076
- wp_enqueue_script($strSrc, $strSrc, $deps, '4.1.7');
1077
  $deps[] = $strSrc;
1078
  }
1079
 
@@ -1113,11 +1113,11 @@ class Gantry
1113
  if ($this->baseUrl != "/") {
1114
  $path = '/' . preg_replace('#^' . quotemeta($this->baseUrl) . '#', "", $path);
1115
  }
1116
- wp_enqueue_script($path, $path, $deps, '4.1.7', true);
1117
  $deps[] = $path;
1118
  }
1119
  foreach ($this->_footer_full_scripts as $strSrc) {
1120
- wp_enqueue_script($strSrc, $strSrc, $deps, '4.1.7', true);
1121
  $deps[] = $strSrc;
1122
  }
1123
 
@@ -1765,7 +1765,7 @@ class Gantry
1765
  if (!defined('GANTRY_FINALIZED')) {
1766
  $this->_styles[$priority][] = $link;
1767
  } else {
1768
- wp_enqueue_style($link->getUrl(), $link->getUrl(), array(), '4.1.7');
1769
  }
1770
  }
1771
  }
@@ -1879,7 +1879,7 @@ class Gantry
1879
  $this->_footerscripts[$full_path] = $check_url_path . $query_string;
1880
  }
1881
  } else {
1882
- wp_enqueue_script($check_url_path, $check_url_path, array(), '4.1.7', $in_footer);
1883
  }
1884
  break;
1885
  }
@@ -1917,7 +1917,7 @@ class Gantry
1917
  $this->_footerscripts[$check_path] = $check_url_path . $query_string;
1918
  }
1919
  } else {
1920
- wp_enqueue_script($check_url_path, $check_url_path, array(), '4.1.7', $in_footer);
1921
  }
1922
  break(2);
1923
  }
1056
  $path = '/' . preg_replace('#^' . quotemeta($this->baseUrl) . '#', "", $path);
1057
  }
1058
  $filename = strtolower(basename($path, '.css')) . rand(0, 1000);
1059
+ wp_enqueue_style($filename, $path, array(), '4.1.8');
1060
  $deps[] = $path;
1061
  }
1062
  }
1069
  if ($this->baseUrl != "/") {
1070
  $path = '/' . preg_replace('#^' . quotemeta($this->baseUrl) . '#', "", $path);
1071
  }
1072
+ wp_enqueue_script($path, $path, $deps, '4.1.8');
1073
  $deps[] = $path;
1074
  }
1075
  foreach ($this->_header_full_scripts as $strSrc) {
1076
+ wp_enqueue_script($strSrc, $strSrc, $deps, '4.1.8');
1077
  $deps[] = $strSrc;
1078
  }
1079
 
1113
  if ($this->baseUrl != "/") {
1114
  $path = '/' . preg_replace('#^' . quotemeta($this->baseUrl) . '#', "", $path);
1115
  }
1116
+ wp_enqueue_script($path, $path, $deps, '4.1.8', true);
1117
  $deps[] = $path;
1118
  }
1119
  foreach ($this->_footer_full_scripts as $strSrc) {
1120
+ wp_enqueue_script($strSrc, $strSrc, $deps, '4.1.8', true);
1121
  $deps[] = $strSrc;
1122
  }
1123
 
1765
  if (!defined('GANTRY_FINALIZED')) {
1766
  $this->_styles[$priority][] = $link;
1767
  } else {
1768
+ wp_enqueue_style($link->getUrl(), $link->getUrl(), array(), '4.1.8');
1769
  }
1770
  }
1771
  }
1879
  $this->_footerscripts[$full_path] = $check_url_path . $query_string;
1880
  }
1881
  } else {
1882
+ wp_enqueue_script($check_url_path, $check_url_path, array(), '4.1.8', $in_footer);
1883
  }
1884
  break;
1885
  }
1917
  $this->_footerscripts[$check_path] = $check_url_path . $query_string;
1918
  }
1919
  } else {
1920
+ wp_enqueue_script($check_url_path, $check_url_path, array(), '4.1.8', $in_footer);
1921
  }
1922
  break(2);
1923
  }
core/utilities/gantrycache.class.php CHANGED
@@ -26,7 +26,7 @@ class GantryCache
26
  /**
27
  *
28
  */
29
- const ADMIN_GROUP_NAME = 'GantryAdmin-4.1.7';
30
 
31
  const ADMIN_LIFETIME = 86400;
32
 
@@ -122,7 +122,7 @@ class GantryCache
122
  $this->cache->addDriver('frontend', new WpTransientCacheDriver($this->group, $this->lifetime));
123
  } elseif (is_admin()) {
124
  // TODO get lifetime for backend cache
125
- $this->group = self::ADMIN_GROUP_NAME . '-4.1.7';
126
  $this->cache->addDriver('admin', new WpTransientCacheDriver($this->group, self::ADMIN_LIFETIME));
127
  }
128
  }
26
  /**
27
  *
28
  */
29
+ const ADMIN_GROUP_NAME = 'GantryAdmin-4.1.8';
30
 
31
  const ADMIN_LIFETIME = 86400;
32
 
122
  $this->cache->addDriver('frontend', new WpTransientCacheDriver($this->group, $this->lifetime));
123
  } elseif (is_admin()) {
124
  // TODO get lifetime for backend cache
125
+ $this->group = self::ADMIN_GROUP_NAME . '-4.1.8';
126
  $this->cache->addDriver('admin', new WpTransientCacheDriver($this->group, self::ADMIN_LIFETIME));
127
  }
128
  }
functions.php CHANGED
@@ -1,6 +1,6 @@
1
  <?php
2
  /**
3
- * @version $Id: functions.php 61393 2015-07-03 07:47:35Z jakub $
4
  * @author RocketTheme http://www.rockettheme.com
5
  * @copyright Copyright (C) 2007 - 2015 RocketTheme, LLC
6
  * @license http://www.gnu.org/licenses/gpl-2.0.html GNU/GPLv2 only
@@ -168,7 +168,7 @@ function gantry_construct()
168
  /**
169
  * @name GANTRY_VERSION
170
  */
171
- define('GANTRY_VERSION', '4.1.7');
172
 
173
 
174
  if (!defined('DS')) {
@@ -201,11 +201,24 @@ function gantry_construct()
201
 
202
  $domain = 'gantry';
203
  $locale = apply_filters( 'plugin_locale', get_locale(), $domain );
 
 
204
 
205
  load_theme_textdomain($domain);
206
- load_theme_textdomain($domain, $gantry->templatePath . '/languages');
 
 
 
 
 
 
207
  load_textdomain($domain, WP_LANG_DIR . '/gantry/' . $domain . '-' . $locale . '.mo');
208
- load_plugin_textdomain($domain, false, basename($gantry_path) . '/languages/');
 
 
 
 
 
209
 
210
  // Load the widget positions for the template
211
  $gantry->loadWidgetPositions();
@@ -213,6 +226,15 @@ function gantry_construct()
213
  }
214
  }
215
 
 
 
 
 
 
 
 
 
 
216
  function gantry_load_template_lang_action()
217
  {
218
  if (defined('NONGANTRY_TEMPLATE')) return;
1
  <?php
2
  /**
3
+ * @version $Id: functions.php 61594 2015-09-04 10:30:15Z jakub $
4
  * @author RocketTheme http://www.rockettheme.com
5
  * @copyright Copyright (C) 2007 - 2015 RocketTheme, LLC
6
  * @license http://www.gnu.org/licenses/gpl-2.0.html GNU/GPLv2 only
168
  /**
169
  * @name GANTRY_VERSION
170
  */
171
+ define('GANTRY_VERSION', '4.1.8');
172
 
173
 
174
  if (!defined('DS')) {
201
 
202
  $domain = 'gantry';
203
  $locale = apply_filters( 'plugin_locale', get_locale(), $domain );
204
+ $languages_path = basename($gantry_path) . '/languages/';
205
+ $theme_languages_path = $gantry->templatePath . '/languages';
206
 
207
  load_theme_textdomain($domain);
208
+
209
+ if( load_theme_textdomain($domain, $theme_languages_path) === false ) {
210
+ add_filter( 'theme_locale', 'gantry_modify_locale', 10, 2 );
211
+ }
212
+
213
+ load_theme_textdomain($domain, $theme_languages_path);
214
+
215
  load_textdomain($domain, WP_LANG_DIR . '/gantry/' . $domain . '-' . $locale . '.mo');
216
+
217
+ if( load_plugin_textdomain( $domain, false, $languages_path ) === false ) {
218
+ add_filter( 'plugin_locale', 'gantry_modify_locale', 10, 2 );
219
+ }
220
+
221
+ load_plugin_textdomain($domain, false, $languages_path);
222
 
223
  // Load the widget positions for the template
224
  $gantry->loadWidgetPositions();
226
  }
227
  }
228
 
229
+ function gantry_modify_locale( $locale, $domain ) {
230
+ // Revert the gantry domain locale to en_US
231
+ if( isset( $domain ) && $domain == 'gantry' ) {
232
+ $locale = 'en_US';
233
+ }
234
+
235
+ return $locale;
236
+ }
237
+
238
  function gantry_load_template_lang_action()
239
  {
240
  if (defined('NONGANTRY_TEMPLATE')) return;
gantry.php CHANGED
@@ -1,16 +1,16 @@
1
  <?php
2
  /**
3
- * @version $Id: gantry.php 61146 2014-11-10 18:10:43Z jakub $
4
  * @author RocketTheme http://www.rockettheme.com
5
  * @copyright Copyright (C) 2007 - 2015 RocketTheme, LLC
6
  * @license http://www.gnu.org/licenses/gpl-2.0.html GNU/GPLv2 only
7
  */
8
 
9
  /*
10
- Plugin Name: Gantry Template Framework
11
- Plugin URI: http://www.gantry-framework.org/
12
  Description: This is a Framework to support easily modifiable themes that are very extensible.
13
- Version: 4.1.7
14
  Author: RocketTheme
15
  Author URI: http://www.rockettheme.com/wordpress
16
  License: http://www.gnu.org/licenses/gpl-2.0.html GNU/GPLv2 only
1
  <?php
2
  /**
3
+ * @version $Id: gantry.php 61592 2015-09-04 10:11:08Z jakub $
4
  * @author RocketTheme http://www.rockettheme.com
5
  * @copyright Copyright (C) 2007 - 2015 RocketTheme, LLC
6
  * @license http://www.gnu.org/licenses/gpl-2.0.html GNU/GPLv2 only
7
  */
8
 
9
  /*
10
+ Plugin Name: Gantry 4 Framework
11
+ Plugin URI: http://www.gantry.org/
12
  Description: This is a Framework to support easily modifiable themes that are very extensible.
13
+ Version: 4.1.8
14
  Author: RocketTheme
15
  Author URI: http://www.rockettheme.com/wordpress
16
  License: http://www.gnu.org/licenses/gpl-2.0.html GNU/GPLv2 only
gizmos/wpml.php CHANGED
@@ -55,7 +55,9 @@ class GantryGizmoWPML extends GantryGizmo {
55
  add_action( 'gantry_assignment_custom_meta_boxes', array( &$this, 'gantry_assignment_wpml_languages_meta_boxes' ) );
56
 
57
  // re-registers ICL Language Switcher widget to extend it for missing form needed for widget variations
58
- add_action( 'widgets_init', array( &$this, 'reregister_language_switcher_widget' ), 11 );
 
 
59
 
60
  // remove possibility of converting regular text widgets to multilingual ones so it wouldn't break Gantry widget structure
61
  if( defined( 'ICL_SITEPRESS_VERSION' ) && ! ICL_PLUGIN_INACTIVE ) {
55
  add_action( 'gantry_assignment_custom_meta_boxes', array( &$this, 'gantry_assignment_wpml_languages_meta_boxes' ) );
56
 
57
  // re-registers ICL Language Switcher widget to extend it for missing form needed for widget variations
58
+ if( class_exists( 'ICL_Language_Switcher' ) ) {
59
+ add_action( 'widgets_init', array( &$this, 'reregister_language_switcher_widget' ), 11 );
60
+ }
61
 
62
  // remove possibility of converting regular text widgets to multilingual ones so it wouldn't break Gantry widget structure
63
  if( defined( 'ICL_SITEPRESS_VERSION' ) && ! ICL_PLUGIN_INACTIVE ) {
readme.txt CHANGED
@@ -3,13 +3,15 @@ Contributors: gantry
3
  Author URI: http://gantry.org
4
  Tags: gantry, framework, template, theme, widgets, flexible, extensible, configurable, 960px, grid, columns, powerful, buddypress
5
  Requires at least: 3.2
6
- Tested up to: 4.3
7
- Stable tag: 4.1.7
8
 
9
- Gantry 4 is a comprehensive set of building blocks to enable the rapid development and realization of a design into a flexible and powerful web platform
10
 
11
  == Description ==
12
 
 
 
13
  Gantry 4 is a comprehensive set of building blocks to enable the rapid development and realization of a design into a flexible and powerful web platform theme.
14
 
15
  * Please visit http://gantry.org to download a FREE WordPress Gantry 4 default theme which can be used as a base for your own themes!
@@ -87,6 +89,11 @@ Once you downloaded and installed Gantry 4 Framework plugin, please download als
87
 
88
  == Changelog ==
89
 
 
 
 
 
 
90
  = 4.1.7 =
91
  * Updated FontAwesome to 4.4.0
92
 
@@ -411,6 +418,9 @@ Once you downloaded and installed Gantry 4 Framework plugin, please download als
411
 
412
  == Upgrade Notice ==
413
 
 
 
 
414
  = 4.1.7 =
415
  Please remember to create a full site backup (files + database) before performing update.
416
 
3
  Author URI: http://gantry.org
4
  Tags: gantry, framework, template, theme, widgets, flexible, extensible, configurable, 960px, grid, columns, powerful, buddypress
5
  Requires at least: 3.2
6
+ Tested up to: 4.3.1
7
+ Stable tag: 4.1.8
8
 
9
+ Gantry is a comprehensive set of building blocks to enable the rapid development and realization of a design into a flexible and powerful web platform
10
 
11
  == Description ==
12
 
13
+ > Gantry 5 is now available for WordPress! Please visit [Gantry 5](https://wordpress.org/plugins/gantry5/ "Gantry 5") plugin page for more informations.
14
+
15
  Gantry 4 is a comprehensive set of building blocks to enable the rapid development and realization of a design into a flexible and powerful web platform theme.
16
 
17
  * Please visit http://gantry.org to download a FREE WordPress Gantry 4 default theme which can be used as a base for your own themes!
89
 
90
  == Changelog ==
91
 
92
+ = 4.1.8 =
93
+ * Fixed fallback to en_US language file if the localized .mo file doesn't exist
94
+ * Fixed Fatal Error that could occur when WPML ICL_Language_Switcher class is missing
95
+ * Changed display of plugin name to Gantry 4 Framework
96
+
97
  = 4.1.7 =
98
  * Updated FontAwesome to 4.4.0
99
 
418
 
419
  == Upgrade Notice ==
420
 
421
+ = 4.1.8 =
422
+ Please remember to create a full site backup (files + database) before performing update.
423
+
424
  = 4.1.7 =
425
  Please remember to create a full site backup (files + database) before performing update.
426
 
widgets/breadcrumbs.php CHANGED
@@ -1,6 +1,6 @@
1
  <?php
2
  /**
3
- * @version 4.1.7 August 18, 2015
4
  * @author RocketTheme http://www.rockettheme.com
5
  * @copyright Copyright (C) 2007 - 2015 RocketTheme, LLC
6
  * @license http://www.gnu.org/licenses/gpl-2.0.html GNU/GPLv2 only
1
  <?php
2
  /**
3
+ * @version 4.1.8 September 18, 2015
4
  * @author RocketTheme http://www.rockettheme.com
5
  * @copyright Copyright (C) 2007 - 2015 RocketTheme, LLC
6
  * @license http://www.gnu.org/licenses/gpl-2.0.html GNU/GPLv2 only
widgets/loginbutton.php CHANGED
@@ -1,6 +1,6 @@
1
  <?php
2
  /**
3
- * @version 4.1.7 August 18, 2015
4
  * @author RocketTheme http://www.rockettheme.com
5
  * @copyright Copyright (C) 2007 - 2015 RocketTheme, LLC
6
  * @license http://www.gnu.org/licenses/gpl-2.0.html GNU/GPLv2 only
1
  <?php
2
  /**
3
+ * @version 4.1.8 September 18, 2015
4
  * @author RocketTheme http://www.rockettheme.com
5
  * @copyright Copyright (C) 2007 - 2015 RocketTheme, LLC
6
  * @license http://www.gnu.org/licenses/gpl-2.0.html GNU/GPLv2 only
widgets/loginform.php CHANGED
@@ -1,6 +1,6 @@
1
  <?php
2
  /**
3
- * @version 4.1.7 August 18, 2015
4
  * @author RocketTheme http://www.rockettheme.com
5
  * @copyright Copyright (C) 2007 - 2015 RocketTheme, LLC
6
  * @license http://www.gnu.org/licenses/gpl-2.0.html GNU/GPLv2 only
1
  <?php
2
  /**
3
+ * @version 4.1.8 September 18, 2015
4
  * @author RocketTheme http://www.rockettheme.com
5
  * @copyright Copyright (C) 2007 - 2015 RocketTheme, LLC
6
  * @license http://www.gnu.org/licenses/gpl-2.0.html GNU/GPLv2 only