Advanced AJAX Product Filters - Version 1.5.5.1

Version Description

  • Enhancement - Compatibility version: Wordpress 5.8 and WooCommerce 5.5
  • Enhancement - Speed up recount functionality for hierarchical taxonomy
  • Fix - Advanced section empty
Download this release

Release Info

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

Code changes from version 1.5.5 to 1.5.5.1

includes/addons/seo_meta_title.php CHANGED
@@ -157,6 +157,9 @@ if( ! class_exists('BeRocket_AAPF_addon_woocommerce_seo_title') ) {
157
  }
158
  $taxonomy_label = apply_filters('wpml_translate_single_string', $taxonomy_label, 'WordPress', sprintf( 'taxonomy singular name: %s', $taxonomy_label ) );
159
  $term = get_term($term_parsed[1], $term_parsed[0]);
 
 
 
160
  if( ! isset($terms_name[$taxonomy->name]) ) {
161
  $terms_name[$taxonomy->name] = array(
162
  'name' => apply_filters('berocket_aapf_seo_meta_filtered_taxonomy_label', $taxonomy_label, $taxonomy, $term, $term_parsed),
157
  }
158
  $taxonomy_label = apply_filters('wpml_translate_single_string', $taxonomy_label, 'WordPress', sprintf( 'taxonomy singular name: %s', $taxonomy_label ) );
159
  $term = get_term($term_parsed[1], $term_parsed[0]);
160
+ if( ! empty($term) && is_a($term, 'WP_Error') ) {
161
+ continue;
162
+ }
163
  if( ! isset($terms_name[$taxonomy->name]) ) {
164
  $terms_name[$taxonomy->name] = array(
165
  'name' => apply_filters('berocket_aapf_seo_meta_filtered_taxonomy_label', $taxonomy_label, $taxonomy, $term, $term_parsed),
includes/admin/admin_bar.php CHANGED
@@ -3,8 +3,10 @@ if( ! class_exists('BeRocket_aapf_admin_bar_debug') ) {
3
  class BeRocket_aapf_admin_bar_debug{
4
  public $footer_run = false, $admin_bar_run = false;
5
  function __construct() {
6
- add_action( 'admin_bar_menu', array($this, 'debug_admin_bar_menu'), 1000 );
7
- add_action( 'wp_footer', array($this, 'footer_bar'), 1000 );
 
 
8
  }
9
  function footer_bar() {
10
  $this->footer_run = true;
3
  class BeRocket_aapf_admin_bar_debug{
4
  public $footer_run = false, $admin_bar_run = false;
5
  function __construct() {
6
+ if( empty($_GET['et_fb']) ) {
7
+ add_action( 'admin_bar_menu', array($this, 'debug_admin_bar_menu'), 1000 );
8
+ add_action( 'wp_footer', array($this, 'footer_bar'), 1000 );
9
+ }
10
  }
11
  function footer_bar() {
12
  $this->footer_run = true;
includes/faster_recount.php CHANGED
@@ -184,9 +184,15 @@ class BeRocket_AAPF_faster_attribute_recount {
184
  JOIN (
185
  SELECT tt1.term_taxonomy_id as tt1id, tt2.term_taxonomy_id as tt2id FROM {$wpdb->term_taxonomy} as tt1
186
  JOIN {$wpdb->term_taxonomy} as tt2 ON (";
187
- $join_list = array();
188
  foreach($hierarchy as $term_id => $term_child) {
189
- $join_list[] = "(tt1.term_id = '{$term_id}' AND tt2.term_id IN('".implode("','", $term_child)."'))";
 
 
 
 
 
 
190
  }
191
  $join_query .= implode('
192
  OR
184
  JOIN (
185
  SELECT tt1.term_taxonomy_id as tt1id, tt2.term_taxonomy_id as tt2id FROM {$wpdb->term_taxonomy} as tt1
186
  JOIN {$wpdb->term_taxonomy} as tt2 ON (";
187
+ $join_list = array("(tt1.term_id = tt2.term_id)");
188
  foreach($hierarchy as $term_id => $term_child) {
189
+ if( count($term_child) > 1 || $term_id != $term_child[0] ) {
190
+ $current = array_search($term_id, $term_child);
191
+ if( $current !== false ) {
192
+ unset($term_child[$current]);
193
+ }
194
+ $join_list[] = "(tt1.term_id = '{$term_id}' AND tt2.term_id IN('".implode("','", $term_child)."'))";
195
+ }
196
  }
197
  $join_query .= implode('
198
  OR
readme.txt CHANGED
@@ -5,7 +5,7 @@ Donate link: https://berocket.com/product/woocommerce-ajax-products-filter?utm_s
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: 5.0
7
  Tested up to: 5.8
8
- Stable tag: 1.5.5
9
  License: GPLv2 or later
10
  License URI: http://www.gnu.org/licenses/gpl-2.0.html
11
 
@@ -185,6 +185,11 @@ You can try this plugin's admin side [here](https://berocket.com/product/woocomm
185
 
186
  == Changelog ==
187
 
 
 
 
 
 
188
  = 1.5.5 =
189
  * Enhancement - Compatibility version: Wordpress 5.8 and WooCommerce 5.5
190
 
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: 5.0
7
  Tested up to: 5.8
8
+ Stable tag: 1.5.5.1
9
  License: GPLv2 or later
10
  License URI: http://www.gnu.org/licenses/gpl-2.0.html
11
 
185
 
186
  == Changelog ==
187
 
188
+ = 1.5.5.1 =
189
+ * Enhancement - Compatibility version: Wordpress 5.8 and WooCommerce 5.5
190
+ * Enhancement - Speed up recount functionality for hierarchical taxonomy
191
+ * Fix - Advanced section empty
192
+
193
  = 1.5.5 =
194
  * Enhancement - Compatibility version: Wordpress 5.8 and WooCommerce 5.5
195
 
templates/single_filter/single_settings_elements.php CHANGED
@@ -152,9 +152,10 @@ if( ! class_exists('braapf_single_filter_edit_elements') ) {
152
  }
153
  static function cat_value_limit($settings_name, $braapf_filter_settings) {
154
  $cat_value_limit = br_get_value_from_array($braapf_filter_settings, 'cat_value_limit', '0');
155
- echo '<div class="braapf_attribute_setup_flex"'
156
- . ( apply_filters('braapf_single_filter_hide_cat_value_limit', empty($cat_value_limit), $cat_value_limit) ? ' style="display:none;"' : '' )
157
- . '>';
 
158
  echo '<div class="braapf_cat_value_limit braapf_full_select_full">';
159
  $hrterms = berocket_aapf_get_terms(array(
160
  'taxonomy' => 'product_cat',
152
  }
153
  static function cat_value_limit($settings_name, $braapf_filter_settings) {
154
  $cat_value_limit = br_get_value_from_array($braapf_filter_settings, 'cat_value_limit', '0');
155
+ if( apply_filters('braapf_single_filter_hide_cat_value_limit', empty($cat_value_limit), $cat_value_limit) ) {
156
+ return;
157
+ }
158
+ echo '<div class="braapf_attribute_setup_flex">';
159
  echo '<div class="braapf_cat_value_limit braapf_full_select_full">';
160
  $hrterms = berocket_aapf_get_terms(array(
161
  'taxonomy' => 'product_cat',
woocommerce-filters.php CHANGED
@@ -3,14 +3,14 @@
3
  * Plugin Name: Advanced AJAX Product Filters for WooCommerce
4
  * Plugin URI: https://wordpress.org/plugins/woocommerce-ajax-filters/?utm_source=free_plugin&utm_medium=plugins&utm_campaign=ajax_filters
5
  * Description: Unlimited AJAX products filters to make your shop perfect
6
- * Version: 1.5.5
7
  * Author: BeRocket
8
  * Requires at least: 5.0
9
  * Author URI: https://berocket.com?utm_source=free_plugin&utm_medium=plugins&utm_campaign=ajax_filters
10
  * Text Domain: BeRocket_AJAX_domain
11
  * Domain Path: /languages/
12
- * WC tested up to: 5.5
13
  */
14
- define( "BeRocket_AJAX_filters_version", '1.5.5' );
15
  define( "BeRocket_AJAX_filters_file", __FILE__ );
16
  include_once('main.php');
3
  * Plugin Name: Advanced AJAX Product Filters for WooCommerce
4
  * Plugin URI: https://wordpress.org/plugins/woocommerce-ajax-filters/?utm_source=free_plugin&utm_medium=plugins&utm_campaign=ajax_filters
5
  * Description: Unlimited AJAX products filters to make your shop perfect
6
+ * Version: 1.5.5.1
7
  * Author: BeRocket
8
  * Requires at least: 5.0
9
  * Author URI: https://berocket.com?utm_source=free_plugin&utm_medium=plugins&utm_campaign=ajax_filters
10
  * Text Domain: BeRocket_AJAX_domain
11
  * Domain Path: /languages/
12
+ * WC tested up to: 5.6
13
  */
14
+ define( "BeRocket_AJAX_filters_version", '1.5.5.1' );
15
  define( "BeRocket_AJAX_filters_file", __FILE__ );
16
  include_once('main.php');