NextGEN Gallery – WordPress Gallery Plugin - Version 2.1.10

Version Description

  • 09.01.2015 =
  • Secured: Escape output of parameters in templates to avoid XSS
Download this release

Release Info

Developer photocrati
Plugin Icon 128x128 NextGEN Gallery – WordPress Gallery Plugin
Version 2.1.10
Comparing to
See all releases

Code changes from version 2.1.9 to 2.1.10

.hg_archival.txt CHANGED
@@ -1,4 +1,4 @@
1
  repo: 2b82bc45fbe039c6f4c9f0c667e9cd1ee4d84cbb
2
- node: eea6705079b13313be58c29ed93bc36b70a95073
3
  branch: default
4
- tag: 2.1.9
1
  repo: 2b82bc45fbe039c6f4c9f0c667e9cd1ee4d84cbb
2
+ node: d017862552ef5106a87f94c3d9959007c0c0f3d5
3
  branch: default
4
+ tag: 2.1.10
.hgtags CHANGED
@@ -314,3 +314,4 @@ e60b028280448eca1c164dd54111623c2edc9997 2.1.3
314
  9c6f1b018b1503530debfbb579e6917ec9bd4cac 2.1.6
315
  b4a06dc685b9d98ae0a082932ef4822be530c429 2.1.7
316
  1f0097e5ccb465c34be15eeadd3e67d44d19dcf6 2.1.8
 
314
  9c6f1b018b1503530debfbb579e6917ec9bd4cac 2.1.6
315
  b4a06dc685b9d98ae0a082932ef4822be530c429 2.1.7
316
  1f0097e5ccb465c34be15eeadd3e67d44d19dcf6 2.1.8
317
+ eea6705079b13313be58c29ed93bc36b70a95073 2.1.9
changelog.txt CHANGED
@@ -1,6 +1,9 @@
1
  NextGEN Gallery
2
  by Photocrati Media
3
 
 
 
 
4
  = V2.1.9 - 08.25.2015 =
5
  * NEW: Added ngg_manage_galleries_items_per_page filter
6
  * NEW: Added ngg_manage_galleries_items_order filter
1
  NextGEN Gallery
2
  by Photocrati Media
3
 
4
+ = V2.1.10 - 09.01.2015 =
5
+ * Secured: Escape output of parameters in templates to avoid XSS
6
+
7
  = V2.1.9 - 08.25.2015 =
8
  * NEW: Added ngg_manage_galleries_items_per_page filter
9
  * NEW: Added ngg_manage_galleries_items_order filter
nggallery.php CHANGED
@@ -4,7 +4,7 @@ if(preg_match('#' . basename(__FILE__) . '#', $_SERVER['PHP_SELF'])) { die('You
4
  /**
5
  * Plugin Name: NextGEN Gallery by Photocrati
6
  * Description: The most popular gallery plugin for WordPress and one of the most popular plugins of all time with over 12 million downloads.
7
- * Version: 2.1.9
8
  * Author: Photocrati Media
9
  * Plugin URI: http://www.nextgen-gallery.com
10
  * Author URI: http://www.photocrati.com
@@ -587,7 +587,7 @@ class C_NextGEN_Bootstrap
587
  define('NGG_PRODUCT_URL', path_join(str_replace("\\", '/', NGG_PLUGIN_URL), 'products'));
588
  define('NGG_MODULE_URL', path_join(str_replace("\\", '/', NGG_PRODUCT_URL), 'photocrati_nextgen/modules'));
589
  define('NGG_PLUGIN_STARTED_AT', microtime());
590
- define('NGG_PLUGIN_VERSION', '2.1.9');
591
 
592
  if (!defined('NGG_HIDE_STRICT_ERRORS')) {
593
  define('NGG_HIDE_STRICT_ERRORS', TRUE);
4
  /**
5
  * Plugin Name: NextGEN Gallery by Photocrati
6
  * Description: The most popular gallery plugin for WordPress and one of the most popular plugins of all time with over 12 million downloads.
7
+ * Version: 2.1.10
8
  * Author: Photocrati Media
9
  * Plugin URI: http://www.nextgen-gallery.com
10
  * Author URI: http://www.photocrati.com
587
  define('NGG_PRODUCT_URL', path_join(str_replace("\\", '/', NGG_PLUGIN_URL), 'products'));
588
  define('NGG_MODULE_URL', path_join(str_replace("\\", '/', NGG_PRODUCT_URL), 'photocrati_nextgen/modules'));
589
  define('NGG_PLUGIN_STARTED_AT', microtime());
590
+ define('NGG_PLUGIN_VERSION', '2.1.10');
591
 
592
  if (!defined('NGG_HIDE_STRICT_ERRORS')) {
593
  define('NGG_HIDE_STRICT_ERRORS', TRUE);
products/photocrati_nextgen/modules/nextgen_admin/package.module.nextgen_admin.php CHANGED
@@ -315,7 +315,7 @@ class Mixin_Form_Field_Generators extends Mixin
315
  {
316
  $hidden = !(isset($display_type->settings['override_thumbnail_settings']) ? $display_type->settings['override_thumbnail_settings'] : FALSE);
317
  $override_field = $this->_render_radio_field($display_type, 'override_thumbnail_settings', __('Override thumbnail settings', 'nggallery'), isset($display_type->settings['override_thumbnail_settings']) ? $display_type->settings['override_thumbnail_settings'] : FALSE, __('This does not affect existing thumbnails; overriding the thumbnail settings will create an additional set of thumbnails. To change the size of existing thumbnails please visit \'Manage Galleries\' and choose \'Create new thumbnails\' for all images in the gallery.', 'nggallery'));
318
- $dimensions_field = $this->object->render_partial('photocrati-nextgen_admin#field_generator/thumbnail_settings', array('display_type_name' => $display_type->name, 'name' => 'thumbnail_dimensions', 'label' => __('Thumbnail dimensions', 'nggallery'), 'thumbnail_width' => isset($display_type->settings['thumbnail_width']) ? $display_type->settings['thumbnail_width'] : 0, 'thumbnail_height' => isset($display_type->settings['thumbnail_height']) ? $display_type->settings['thumbnail_height'] : 0, 'hidden' => $hidden ? 'hidden' : '', 'text' => ''), TRUE);
319
  /*
320
  $qualities = array();
321
  for ($i = 100; $i > 40; $i -= 5) { $qualities[$i] = "{$i}%"; }
315
  {
316
  $hidden = !(isset($display_type->settings['override_thumbnail_settings']) ? $display_type->settings['override_thumbnail_settings'] : FALSE);
317
  $override_field = $this->_render_radio_field($display_type, 'override_thumbnail_settings', __('Override thumbnail settings', 'nggallery'), isset($display_type->settings['override_thumbnail_settings']) ? $display_type->settings['override_thumbnail_settings'] : FALSE, __('This does not affect existing thumbnails; overriding the thumbnail settings will create an additional set of thumbnails. To change the size of existing thumbnails please visit \'Manage Galleries\' and choose \'Create new thumbnails\' for all images in the gallery.', 'nggallery'));
318
+ $dimensions_field = $this->object->render_partial('photocrati-nextgen_admin#field_generator/thumbnail_settings', array('display_type_name' => $display_type->name, 'name' => 'thumbnail_dimensions', 'label' => __('Thumbnail dimensions', 'nggallery'), 'thumbnail_width' => isset($display_type->settings['thumbnail_width']) ? intval($display_type->settings['thumbnail_width']) : 0, 'thumbnail_height' => isset($display_type->settings['thumbnail_height']) ? intval($display_type->settings['thumbnail_height']) : 0, 'hidden' => $hidden ? 'hidden' : '', 'text' => ''), TRUE);
319
  /*
320
  $qualities = array();
321
  for ($i = 100; $i > 40; $i -= 5) { $qualities[$i] = "{$i}%"; }
products/photocrati_nextgen/modules/nextgen_basic_templates/templates/nextgen_basic_templates_settings_template.php CHANGED
@@ -14,7 +14,7 @@
14
  <option></option>
15
  <?php foreach ($templates as $file => $label): ?>
16
  <?php if ($file && $label): ?>
17
- <option value="<?php echo $file; ?>" <?php selected($chosen_file, $file, TRUE); ?>><?php esc_html_e($label); ?></option>
18
  <?php endif ?>
19
  <?php endforeach ?>
20
  </select>
14
  <option></option>
15
  <?php foreach ($templates as $file => $label): ?>
16
  <?php if ($file && $label): ?>
17
+ <option value="<?php esc_attr_e($file) ?>" <?php selected($chosen_file, $file, TRUE); ?>><?php esc_html_e($label); ?></option>
18
  <?php endif ?>
19
  <?php endforeach ?>
20
  </select>
products/photocrati_nextgen/modules/nextgen_other_options/templates/watermarks_tab.php CHANGED
@@ -55,13 +55,13 @@
55
  name='watermark_options[wmXpos]'
56
  placeholder='0'
57
  min='0'
58
- value='<?php echo $offset_x; ?>'/> /
59
  <input type='number'
60
  id='nextgen_settings_wmYpos'
61
  name='watermark_options[wmYpos]'
62
  placeholder='0'
63
  min='0'
64
- value='<?php echo $offset_y; ?>'/>
65
  <label for='nextgen_settings_wmYpos'>h</label>
66
  </td>
67
  </tr>
55
  name='watermark_options[wmXpos]'
56
  placeholder='0'
57
  min='0'
58
+ value='<?php esc_attr_e($offset_x) ?>'/> /
59
  <input type='number'
60
  id='nextgen_settings_wmYpos'
61
  name='watermark_options[wmYpos]'
62
  placeholder='0'
63
  min='0'
64
+ value='<?php esc_attr_e($offset_y) ?>'/>
65
  <label for='nextgen_settings_wmYpos'>h</label>
66
  </td>
67
  </tr>
products/photocrati_nextgen/modules/ngglegacy/admin/thumbnails-template.php CHANGED
@@ -89,16 +89,16 @@ if (!is_null($nextgen_thumb_size_custom_style))
89
  <input type="text"
90
  size="5"
91
  maxlength="5"
92
- id='<?php echo $thumbnails_template_width_id; ?>'
93
- name="<?php echo $thumbnails_template_width_name; ?>"
94
- value="<?php echo $thumbnails_template_width_value; ?>"/>
95
  x
96
  <input type="text"
97
  size="5"
98
  maxlength="5"
99
- id='<?php echo $thumbnails_template_height_id; ?>'
100
- name="<?php echo $thumbnails_template_height_name; ?>"
101
- value="<?php echo $thumbnails_template_height_value; ?>"/>
102
  <br/>
103
  <small><?php _e('These are maximum values', 'nggallery'); ?></small>
104
  </span>
89
  <input type="text"
90
  size="5"
91
  maxlength="5"
92
+ id='<?php esc_attr_e($thumbnails_template_width_id); ?>'
93
+ name="<?php esc_attr_e($thumbnails_template_width_name); ?>"
94
+ value="<?php esc_attr_e($thumbnails_template_width_value); ?>"/>
95
  x
96
  <input type="text"
97
  size="5"
98
  maxlength="5"
99
+ id='<?php esc_attr_e($thumbnails_template_height_id) ?>'
100
+ name="<?php esc_attr_e($thumbnails_template_height_name) ?>"
101
+ value="<?php esc_attr_e($thumbnails_template_height_value) ?>"/>
102
  <br/>
103
  <small><?php _e('These are maximum values', 'nggallery'); ?></small>
104
  </span>
products/photocrati_nextgen/modules/ngglegacy/lib/ngg-db.php CHANGED
@@ -674,10 +674,10 @@ class nggdb
674
  if ($offset && $limit) $mapper->limit($limit, $offset);
675
 
676
  // Add exclusion clause
677
- if ($exclude) $mapper->where(array("exclude = 0"));
678
 
679
  // Add gallery clause
680
- if ($galleryId) $mapper->where(array("galleryid = %d"), $galleryId);
681
 
682
  return $mapper->run_query();
683
  }
674
  if ($offset && $limit) $mapper->limit($limit, $offset);
675
 
676
  // Add exclusion clause
677
+ if ($exclude) $mapper->where(array("exclude = %d", 0));
678
 
679
  // Add gallery clause
680
+ if ($galleryId) $mapper->where(array("galleryid = %d", $galleryId));
681
 
682
  return $mapper->run_query();
683
  }
readme.txt CHANGED
@@ -2,8 +2,8 @@
2
  Contributors: photocrati
3
  Tags: nextgen, nextgen gallery, gallery, galleries, image, images, image gallery, photo, photos, photo gallery, picture, pictures, picture gallery, album, albums, photo albums, image album, media, media gallery, thumbnails, thumbnail gallery, thumbnail galleries, slideshow, slideshows, slideshow gallery, slideshow galleries, fancybox, lightbox, responsive, responsive gallery, responsive galleries, wordpress responsive gallery, nextcellent, wordpress gallery plugin, wordpress photo gallery plugin, wp gallery, wp gallery plugins, best gallery plugin, free photo gallery, singlepic, image captions imagebrowser, watermarks, watermarking, photography, photographer
4
  Requires at least: 3.6.1
5
- Tested up to: 4.3
6
- Stable tag: 2.1.9
7
  License: GPLv2
8
 
9
  The most popular WordPress gallery plugin and one of the most popular plugins of all time with over 13 million downloads.
@@ -199,6 +199,9 @@ For more information, feel free to visit the official website for the NextGEN Ga
199
 
200
  == Changelog ==
201
 
 
 
 
202
  = V2.1.9 - 08.25.2015 =
203
  * NEW: Added ngg_manage_galleries_items_per_page filter
204
  * NEW: Added ngg_manage_galleries_items_order filter
2
  Contributors: photocrati
3
  Tags: nextgen, nextgen gallery, gallery, galleries, image, images, image gallery, photo, photos, photo gallery, picture, pictures, picture gallery, album, albums, photo albums, image album, media, media gallery, thumbnails, thumbnail gallery, thumbnail galleries, slideshow, slideshows, slideshow gallery, slideshow galleries, fancybox, lightbox, responsive, responsive gallery, responsive galleries, wordpress responsive gallery, nextcellent, wordpress gallery plugin, wordpress photo gallery plugin, wp gallery, wp gallery plugins, best gallery plugin, free photo gallery, singlepic, image captions imagebrowser, watermarks, watermarking, photography, photographer
4
  Requires at least: 3.6.1
5
+ Stable tag: 2.1.10
6
+ Tested up to: 4.3.0
7
  License: GPLv2
8
 
9
  The most popular WordPress gallery plugin and one of the most popular plugins of all time with over 13 million downloads.
199
 
200
  == Changelog ==
201
 
202
+ = V2.1.10 - 09.01.2015 =
203
+ * Secured: Escape output of parameters in templates to avoid XSS
204
+
205
  = V2.1.9 - 08.25.2015 =
206
  * NEW: Added ngg_manage_galleries_items_per_page filter
207
  * NEW: Added ngg_manage_galleries_items_order filter