Advanced AJAX Product Filters - Version 1.3.1.6

Version Description

  • Enhancement - Code Security
Download this release

Release Info

Developer RazyRx
Plugin Icon wp plugin Advanced AJAX Product Filters
Version 1.3.1.6
Comparing to
See all releases

Code changes from version 1.3.1.5 to 1.3.1.6

Files changed (3) hide show
  1. includes/new_widget.php +11 -4
  2. readme.txt +4 -1
  3. woocommerce-filters.php +2 -2
includes/new_widget.php CHANGED
@@ -181,21 +181,28 @@ class BeRocket_new_AAPF_Widget_single extends WP_Widget
181
  if( ! empty($filter_data['reset_hide']) && $filter_data['widget_type'] == 'reset_button' ) {
182
  $additional_class[] = $filter_data['reset_hide'];
183
  }
 
 
 
184
  $additional_class = array_unique($additional_class);
185
  if( ! empty($filter_data['widget_type']) && ($filter_data['widget_type'] == 'update_button' || $filter_data['widget_type'] == 'reset_button' ) ) {
186
  $search_berocket_hidden_clickable = array_search('berocket_hidden_clickable', $additional_class);
187
  if( $search_berocket_hidden_clickable !== FALSE ) {
188
  unset($additional_class[$search_berocket_hidden_clickable]);
189
  }
190
- echo '<div class="berocket_single_filter_widget berocket_single_filter_widget_' . esc_html($instance['filter_id']) . ' ' . esc_html($custom_class) . ' ' . implode(' ', $additional_class) . '" data-id="' . esc_html($instance['filter_id']) . '">';
 
 
191
  } else {
 
 
192
  if( ! empty($args['widget_inline_style']) ) {
193
- $classes_arr = 'berocket_single_filter_widget berocket_single_filter_widget_' . esc_html($instance['filter_id']) . ' ' . esc_html($custom_class) . ' ' . implode(' ', $additional_class);
194
  $classes_arr = explode(' ', preg_replace('!\s+!', ' ', $classes_arr));
195
  $classes_arr = '.' . implode('.', $classes_arr);
196
- echo '<style>'.$classes_arr.' .berocket_aapf_widget {' . $args['widget_inline_style'] . '}</style>';
197
  }
198
- echo '<div class="berocket_single_filter_widget berocket_single_filter_widget_' . esc_html($instance['filter_id']) . ' ' . esc_html($custom_class) . ' '.implode(' ', $additional_class).'" data-id="' . esc_html($instance['filter_id']) . '" style="'.br_get_value_from_array($args, 'inline_style').'">';
199
  }
200
  if( apply_filters('BeRocket_AAPF_widget_old_display_conditions', true, $filter_data, $instance, $args) ) {
201
  the_widget( 'BeRocket_AAPF_widget', $filter_data, $args);
181
  if( ! empty($filter_data['reset_hide']) && $filter_data['widget_type'] == 'reset_button' ) {
182
  $additional_class[] = $filter_data['reset_hide'];
183
  }
184
+ $additional_class[] = 'berocket_single_filter_widget';
185
+ $additional_class[] = 'berocket_single_filter_widget_' . esc_html($instance['filter_id']);
186
+ $additional_class[] = $custom_class;
187
  $additional_class = array_unique($additional_class);
188
  if( ! empty($filter_data['widget_type']) && ($filter_data['widget_type'] == 'update_button' || $filter_data['widget_type'] == 'reset_button' ) ) {
189
  $search_berocket_hidden_clickable = array_search('berocket_hidden_clickable', $additional_class);
190
  if( $search_berocket_hidden_clickable !== FALSE ) {
191
  unset($additional_class[$search_berocket_hidden_clickable]);
192
  }
193
+ $additional_class_esc = implode(' ', $additional_class);
194
+ $additional_class_esc = esc_html($additional_class_esc);
195
+ echo '<div class="' . $additional_class_esc . '" data-id="' . esc_html($instance['filter_id']) . '">';
196
  } else {
197
+ $additional_class_esc = implode(' ', $additional_class);
198
+ $additional_class_esc = esc_html($additional_class_esc);
199
  if( ! empty($args['widget_inline_style']) ) {
200
+ $classes_arr = $additional_class_esc;
201
  $classes_arr = explode(' ', preg_replace('!\s+!', ' ', $classes_arr));
202
  $classes_arr = '.' . implode('.', $classes_arr);
203
+ echo '<style>'.$classes_arr.' .berocket_aapf_widget {' . htmlentities($args['widget_inline_style'], ENT_HTML5) . '}</style>';
204
  }
205
+ echo '<div class="' . $additional_class_esc . '" data-id="' . esc_html($instance['filter_id']) . '" style="'.htmlentities(br_get_value_from_array($args, 'inline_style')).'">';
206
  }
207
  if( apply_filters('BeRocket_AAPF_widget_old_display_conditions', true, $filter_data, $instance, $args) ) {
208
  the_widget( 'BeRocket_AAPF_widget', $filter_data, $args);
readme.txt CHANGED
@@ -5,7 +5,7 @@ Donate link: http://berocket.com/product/woocommerce-ajax-products-filter
5
  Tags: filters, product filters, ajax product filters, ajax filter, ajax filter widget, color filter, size filter, product onsale filter, product preview, product category filter, product reset filter, product sort by filter, stock filter, product tag filter, price range filter, price box filter, advanced product filters, woocommerce filters, woocommerce product filters, woocommerce products filter, woocommerce ajax product filters, widget, plugin, woocommerce item filters, filters plugin, ajax filters plugin, filter woocommerce products, filter woocommerce products plugin, wc filters, wc filters products, wc products filters, wc ajax products filters, wc product filters, wc advanced product filters, woocommerce layered nav, woocommerce layered navigation, ajax filtered nav, ajax filtered navigation, price filter, ajax price filter, woocommerce product sorting, sidebar filter, sidebar ajax filter, taxonomy filter, category filter, attribute filter, attributes filter, woocommerce product sort, ajax products filter plugin for woocommerce, rocket, berocket, berocket woocommerce ajax products filter
6
  Requires at least: 4.0
7
  Tested up to: 5.1.1
8
- Stable tag: 1.3.1.5
9
  License: GPLv2 or later
10
  License URI: http://www.gnu.org/licenses/gpl-2.0.html
11
 
@@ -187,6 +187,9 @@ You can try this plugin's admin side [here](http://berocket.com/product/woocomme
187
 
188
  == Changelog ==
189
 
 
 
 
190
  = 1.3.1.5 =
191
  * Enhancement - Code Security
192
 
5
  Tags: filters, product filters, ajax product filters, ajax filter, ajax filter widget, color filter, size filter, product onsale filter, product preview, product category filter, product reset filter, product sort by filter, stock filter, product tag filter, price range filter, price box filter, advanced product filters, woocommerce filters, woocommerce product filters, woocommerce products filter, woocommerce ajax product filters, widget, plugin, woocommerce item filters, filters plugin, ajax filters plugin, filter woocommerce products, filter woocommerce products plugin, wc filters, wc filters products, wc products filters, wc ajax products filters, wc product filters, wc advanced product filters, woocommerce layered nav, woocommerce layered navigation, ajax filtered nav, ajax filtered navigation, price filter, ajax price filter, woocommerce product sorting, sidebar filter, sidebar ajax filter, taxonomy filter, category filter, attribute filter, attributes filter, woocommerce product sort, ajax products filter plugin for woocommerce, rocket, berocket, berocket woocommerce ajax products filter
6
  Requires at least: 4.0
7
  Tested up to: 5.1.1
8
+ Stable tag: 1.3.1.6
9
  License: GPLv2 or later
10
  License URI: http://www.gnu.org/licenses/gpl-2.0.html
11
 
187
 
188
  == Changelog ==
189
 
190
+ = 1.3.1.6 =
191
+ * Enhancement - Code Security
192
+
193
  = 1.3.1.5 =
194
  * Enhancement - Code Security
195
 
woocommerce-filters.php CHANGED
@@ -3,7 +3,7 @@
3
  * Plugin Name: Advanced AJAX Product Filters for WooCommerce
4
  * Plugin URI: https://wordpress.org/plugins/woocommerce-ajax-filters/
5
  * Description: Unlimited AJAX products filters to make your shop perfect
6
- * Version: 1.3.1.5
7
  * Author: BeRocket
8
  * Requires at least: 4.0
9
  * Author URI: http://berocket.com
@@ -13,6 +13,6 @@
13
  * Domain Path: /languages/
14
  * WC tested up to: 3.5.7
15
  */
16
- define( "BeRocket_AJAX_filters_version", '1.3.1.5' );
17
  define( "BeRocket_AJAX_filters_file", __FILE__ );
18
  include_once('main.php');
3
  * Plugin Name: Advanced AJAX Product Filters for WooCommerce
4
  * Plugin URI: https://wordpress.org/plugins/woocommerce-ajax-filters/
5
  * Description: Unlimited AJAX products filters to make your shop perfect
6
+ * Version: 1.3.1.6
7
  * Author: BeRocket
8
  * Requires at least: 4.0
9
  * Author URI: http://berocket.com
13
  * Domain Path: /languages/
14
  * WC tested up to: 3.5.7
15
  */
16
+ define( "BeRocket_AJAX_filters_version", '1.3.1.6' );
17
  define( "BeRocket_AJAX_filters_file", __FILE__ );
18
  include_once('main.php');