Advanced Woo Search - Version 1.69

Version Description

  • Dev - Update security checks
  • Dev - Add aws_front_data_parameters filter
Download this release

Release Info

Developer Mihail Barinov
Plugin Icon 128x128 Advanced Woo Search
Version 1.69
Comparing to
See all releases

Code changes from version 1.68 to 1.69

advanced-woo-search.php CHANGED
@@ -3,7 +3,7 @@
3
  /*
4
  Plugin Name: Advanced Woo Search
5
  Description: Advance ajax WooCommerce product search.
6
- Version: 1.68
7
  Author: ILLID
8
  Author URI: https://advanced-woo-search.com/
9
  Text Domain: aws
@@ -16,7 +16,7 @@ if ( ! defined( 'ABSPATH' ) ) {
16
  exit;
17
  }
18
 
19
- define( 'AWS_VERSION', '1.68' );
20
 
21
 
22
  define( 'AWS_DIR', dirname( __FILE__ ) );
@@ -150,10 +150,10 @@ final class AWS_Main {
150
  wp_enqueue_style( 'aws-style', AWS_URL . '/assets/css/common.css', array(), AWS_VERSION );
151
  wp_enqueue_script('aws-script', AWS_URL . '/assets/js/common.js', array('jquery'), AWS_VERSION, true);
152
  wp_localize_script('aws-script', 'aws_vars', array(
153
- 'sale' => __('Sale!', 'aws'),
154
- 'sku' => __('SKU', 'aws'),
155
- 'showmore' => $this->get_settings('show_more_text') ? AWS_Helpers::translate( 'show_more_text', stripslashes( $this->get_settings('show_more_text') ) ) : __('View all results', 'aws'),
156
- 'noresults' => $this->get_settings('not_found_text') ? AWS_Helpers::translate( 'not_found_text', stripslashes( $this->get_settings('not_found_text') ) ) : __('Nothing found', 'aws')
157
  ));
158
  }
159
 
@@ -164,10 +164,10 @@ final class AWS_Main {
164
  $plugin_base = plugin_basename( __FILE__ );
165
 
166
  if ( $file == $plugin_base ) {
167
- $setting_link = '<a href="' . admin_url('admin.php?page=aws-options') . '">'.__( 'Settings', 'aws' ).'</a>';
168
  array_unshift( $links, $setting_link );
169
 
170
- $premium_link = '<a href="https://advanced-woo-search.com/?utm_source=plugin&utm_medium=settings-link&utm_campaign=aws-pro-plugin" target="_blank">'.__( 'Get Premium', 'aws' ).'</a>';
171
  array_unshift( $links, $premium_link );
172
  }
173
 
@@ -246,7 +246,7 @@ function aws_is_plugin_active_for_network( $plugin ) {
246
  function aws_install_woocommerce_admin_notice() {
247
  ?>
248
  <div class="error">
249
- <p><?php _e( 'Advanced Woo Search plugin is enabled but not effective. It requires WooCommerce in order to work.', 'aws' ); ?></p>
250
  </div>
251
  <?php
252
  }
3
  /*
4
  Plugin Name: Advanced Woo Search
5
  Description: Advance ajax WooCommerce product search.
6
+ Version: 1.69
7
  Author: ILLID
8
  Author URI: https://advanced-woo-search.com/
9
  Text Domain: aws
16
  exit;
17
  }
18
 
19
+ define( 'AWS_VERSION', '1.69' );
20
 
21
 
22
  define( 'AWS_DIR', dirname( __FILE__ ) );
150
  wp_enqueue_style( 'aws-style', AWS_URL . '/assets/css/common.css', array(), AWS_VERSION );
151
  wp_enqueue_script('aws-script', AWS_URL . '/assets/js/common.js', array('jquery'), AWS_VERSION, true);
152
  wp_localize_script('aws-script', 'aws_vars', array(
153
+ 'sale' => __('Sale!', 'aws'),
154
+ 'sku' => __('SKU', 'aws'),
155
+ 'showmore' => $this->get_settings('show_more_text') ? AWS_Helpers::translate( 'show_more_text', stripslashes( $this->get_settings('show_more_text') ) ) : __('View all results', 'aws'),
156
+ 'noresults' => $this->get_settings('not_found_text') ? AWS_Helpers::translate( 'not_found_text', stripslashes( $this->get_settings('not_found_text') ) ) : __('Nothing found', 'aws'),
157
  ));
158
  }
159
 
164
  $plugin_base = plugin_basename( __FILE__ );
165
 
166
  if ( $file == $plugin_base ) {
167
+ $setting_link = '<a href="' . admin_url('admin.php?page=aws-options') . '">'.esc_html__( 'Settings', 'aws' ).'</a>';
168
  array_unshift( $links, $setting_link );
169
 
170
+ $premium_link = '<a href="https://advanced-woo-search.com/?utm_source=plugin&utm_medium=settings-link&utm_campaign=aws-pro-plugin" target="_blank">'.esc_html__( 'Get Premium', 'aws' ).'</a>';
171
  array_unshift( $links, $premium_link );
172
  }
173
 
246
  function aws_install_woocommerce_admin_notice() {
247
  ?>
248
  <div class="error">
249
+ <p><?php esc_html_e( 'Advanced Woo Search plugin is enabled but not effective. It requires WooCommerce in order to work.', 'aws' ); ?></p>
250
  </div>
251
  <?php
252
  }
assets/js/admin.js CHANGED
@@ -37,7 +37,8 @@ jQuery(document).ready(function ($) {
37
  url: ajaxurl,
38
  data: {
39
  action: 'aws-reindex',
40
- data: data
 
41
  },
42
  dataType: "json",
43
  timeout:0,
@@ -116,7 +117,8 @@ jQuery(document).ready(function ($) {
116
  type: 'POST',
117
  url: ajaxurl,
118
  data: {
119
- action: 'aws-clear-cache'
 
120
  },
121
  dataType: "json",
122
  success: function (data) {
37
  url: ajaxurl,
38
  data: {
39
  action: 'aws-reindex',
40
+ data: data,
41
+ _ajax_nonce: aws_vars.ajax_nonce
42
  },
43
  dataType: "json",
44
  timeout:0,
117
  type: 'POST',
118
  url: ajaxurl,
119
  data: {
120
+ action: 'aws-clear-cache',
121
+ _ajax_nonce: aws_vars.ajax_nonce
122
  },
123
  dataType: "json",
124
  success: function (data) {
includes/class-aws-admin-fields.php CHANGED
@@ -53,9 +53,9 @@ if ( ! class_exists( 'AWS_Admin_Fields' ) ) :
53
 
54
  case 'text': ?>
55
  <tr valign="top">
56
- <th scope="row"><?php echo $value['name']; ?></th>
57
  <td>
58
- <input type="text" name="<?php echo $value['id']; ?>" class="regular-text" value="<?php echo isset( $plugin_options[ $value['id'] ] ) ? stripslashes( $plugin_options[ $value['id'] ] ) : ''; ?>">
59
  <br><span class="description"><?php echo $value['desc']; ?></span>
60
  </td>
61
  </tr>
@@ -63,20 +63,20 @@ if ( ! class_exists( 'AWS_Admin_Fields' ) ) :
63
 
64
  case 'image': ?>
65
  <tr valign="top">
66
- <th scope="row"><?php echo $value['name']; ?></th>
67
  <td>
68
- <input type="text" name="<?php echo $value['id']; ?>" class="regular-text" value="<?php echo stripslashes( $plugin_options[ $value['id'] ] ); ?>">
69
  <br><span class="description"><?php echo $value['desc']; ?></span>
70
- <img style="display: block;max-width: 100px;margin-top: 20px;" src="<?php echo stripslashes( $plugin_options[ $value['id'] ] ); ?>">
71
  </td>
72
  </tr>
73
  <?php break;
74
 
75
  case 'number': ?>
76
  <tr valign="top">
77
- <th scope="row"><?php echo $value['name']; ?></th>
78
  <td>
79
- <input type="number" name="<?php echo $value['id']; ?>" class="regular-text" value="<?php echo stripslashes( $plugin_options[ $value['id'] ] ); ?>">
80
  <br><span class="description"><?php echo $value['desc']; ?></span>
81
  </td>
82
  </tr>
@@ -84,9 +84,9 @@ if ( ! class_exists( 'AWS_Admin_Fields' ) ) :
84
 
85
  case 'textarea': ?>
86
  <tr valign="top">
87
- <th scope="row"><?php echo $value['name']; ?></th>
88
  <td>
89
- <textarea id="<?php echo $value['id']; ?>" name="<?php echo $value['id']; ?>" cols="65" rows="4"><?php print stripslashes( $plugin_options[ $value['id'] ] ); ?></textarea>
90
  <br><span class="description"><?php echo $value['desc']; ?></span>
91
  </td>
92
  </tr>
@@ -94,11 +94,11 @@ if ( ! class_exists( 'AWS_Admin_Fields' ) ) :
94
 
95
  case 'checkbox': ?>
96
  <tr valign="top">
97
- <th scope="row"><?php echo $value['name']; ?></th>
98
  <td>
99
  <?php $checkbox_options = $plugin_options[ $value['id'] ]; ?>
100
  <?php foreach ( $value['choices'] as $val => $label ) { ?>
101
- <input type="checkbox" name="<?php echo $value['id'] . '[' . $val . ']'; ?>" id="<?php echo $value['id'] . '_' . $val; ?>" value="1" <?php checked( $checkbox_options[$val], '1' ); ?>> <label for="<?php echo $value['id'] . '_' . $val; ?>"><?php echo $label; ?></label><br>
102
  <?php } ?>
103
  <br><span class="description"><?php echo $value['desc']; ?></span>
104
  </td>
@@ -107,10 +107,10 @@ if ( ! class_exists( 'AWS_Admin_Fields' ) ) :
107
 
108
  case 'radio': ?>
109
  <tr valign="top">
110
- <th scope="row"><?php echo $value['name']; ?></th>
111
  <td>
112
  <?php foreach ( $value['choices'] as $val => $label ) { ?>
113
- <input class="radio" type="radio" name="<?php echo $value['id']; ?>" id="<?php echo $value['id'].$val; ?>" value="<?php echo $val; ?>" <?php checked( $plugin_options[ $value['id'] ], $val ); ?>> <label for="<?php echo $value['id'].$val; ?>"><?php echo $label; ?></label><br>
114
  <?php } ?>
115
  <br><span class="description"><?php echo $value['desc']; ?></span>
116
  </td>
@@ -119,11 +119,11 @@ if ( ! class_exists( 'AWS_Admin_Fields' ) ) :
119
 
120
  case 'select': ?>
121
  <tr valign="top">
122
- <th scope="row"><?php echo $value['name']; ?></th>
123
  <td>
124
- <select name="<?php echo $value['id']; ?>">
125
  <?php foreach ( $value['choices'] as $val => $label ) { ?>
126
- <option value="<?php echo $val; ?>" <?php selected( $plugin_options[ $value['id'] ], $val ); ?>><?php echo $label; ?></option>
127
  <?php } ?>
128
  </select>
129
  <br><span class="description"><?php echo $value['desc']; ?></span>
@@ -133,13 +133,13 @@ if ( ! class_exists( 'AWS_Admin_Fields' ) ) :
133
 
134
  case 'select_advanced': ?>
135
  <tr valign="top">
136
- <th scope="row"><?php echo $value['name']; ?></th>
137
  <td>
138
- <select name="<?php echo $value['id'].'[]'; ?>" multiple class="chosen-select">
139
  <?php $values = $plugin_options[ $value['id'] ]; ?>
140
  <?php foreach ( $value['choices'] as $val => $label ) { ?>
141
  <?php $selected = ( is_array( $values ) && in_array( $val, $values ) ) ? ' selected="selected" ' : ''; ?>
142
- <option value="<?php echo $val; ?>"<?php echo $selected; ?>><?php echo $label; ?></option>
143
  <?php } ?>
144
  </select>
145
  <br><span class="description"><?php echo $value['desc']; ?></span>
@@ -148,9 +148,9 @@ if ( ! class_exists( 'AWS_Admin_Fields' ) ) :
148
  <?php $sub_options = $value['sub_option']; ?>
149
  <br><br>
150
  <p>
151
- <label for="<?php echo $sub_options['id']; ?>">
152
- <input type="checkbox" value="1" id="<?php echo $sub_options['id']; ?>" name="<?php echo $sub_options['id']; ?>" <?php checked( $plugin_options[ $sub_options['id'] ], '1' ); ?>>
153
- <?php echo $sub_options['desc']; ?>
154
  </label>
155
  </p>
156
  <?php endif; ?>
@@ -161,13 +161,13 @@ if ( ! class_exists( 'AWS_Admin_Fields' ) ) :
161
 
162
  case 'radio-image': ?>
163
  <tr valign="top">
164
- <th scope="row"><?php echo $value['name']; ?></th>
165
  <td>
166
  <ul class="img-select">
167
  <?php foreach ( $value['choices'] as $val => $img ) { ?>
168
  <li class="option">
169
- <input class="radio" type="radio" name="<?php echo $value['id']; ?>" id="<?php echo $value['id'].$val; ?>" value="<?php echo $val; ?>" <?php checked( $plugin_options[ $value['id'] ], $val ); ?>>
170
- <span class="ico" style="background: url('<?php echo AWS_URL . '/assets/img/' . $img; ?>') no-repeat 50% 50%;"></span>
171
  </li>
172
  <?php } ?>
173
  </ul>
@@ -178,7 +178,7 @@ if ( ! class_exists( 'AWS_Admin_Fields' ) ) :
178
 
179
  case 'sortable': ?>
180
  <tr valign="top">
181
- <th scope="row"><?php echo $value['name']; ?></th>
182
  <td>
183
 
184
  <script>
@@ -195,7 +195,7 @@ if ( ! class_exists( 'AWS_Admin_Fields' ) ) :
195
 
196
  });
197
  var serviceListOut = serviceList.substring(1);
198
- jQuery('#<?php echo $value['id']; ?>').attr('value', serviceListOut);
199
  }
200
  }).disableSelection();
201
 
@@ -213,8 +213,8 @@ if ( ! class_exists( 'AWS_Admin_Fields' ) ) :
213
  <div class="sortable-container">
214
 
215
  <div class="sortable-title">
216
- <?php _e( 'Active sources', 'aws' ) ?><br>
217
- <?php _e( 'Change order by drag&drop', 'aws' ) ?>
218
  </div>
219
 
220
  <ul id="sti-sortable2" class="sti-sortable enabled connectedSortable">
@@ -222,7 +222,7 @@ if ( ! class_exists( 'AWS_Admin_Fields' ) ) :
222
  if ( count( $active_buttons ) > 0 ) {
223
  foreach ($active_buttons as $button) {
224
  if ( ! $button ) continue;
225
- echo '<li id="' . $button . '" class="sti-btn sti-' . $button . '-btn">' . $button . '</li>';
226
  }
227
  }
228
  ?>
@@ -233,15 +233,15 @@ if ( ! class_exists( 'AWS_Admin_Fields' ) ) :
233
  <div class="sortable-container">
234
 
235
  <div class="sortable-title">
236
- <?php _e( 'Deactivated sources', 'aws' ) ?><br>
237
- <?php _e( 'Excluded from search results', 'aws' ) ?>
238
  </div>
239
 
240
  <ul id="sti-sortable1" class="sti-sortable disabled connectedSortable">
241
  <?php
242
  if ( count( $inactive_buttons ) > 0 ) {
243
  foreach ($inactive_buttons as $button) {
244
- echo '<li id="' . $button . '" class="sti-btn sti-' . $button . '-btn">' . $button . '</li>';
245
  }
246
  }
247
  ?>
@@ -249,7 +249,7 @@ if ( ! class_exists( 'AWS_Admin_Fields' ) ) :
249
 
250
  </div>
251
 
252
- <input type="hidden" id="<?php echo $value['id']; ?>" name="<?php echo $value['id']; ?>" value="<?php echo $plugin_options[ $value['id'] ]; ?>" />
253
 
254
  </td>
255
  </tr>
@@ -257,7 +257,7 @@ if ( ! class_exists( 'AWS_Admin_Fields' ) ) :
257
 
258
  case 'heading': ?>
259
  <tr valign="top">
260
- <th scope="row"><h3 class="aws-heading"><?php echo $value['name']; ?></h3></th>
261
  </tr>
262
  <?php break;
263
 
@@ -268,7 +268,7 @@ if ( ! class_exists( 'AWS_Admin_Fields' ) ) :
268
  echo '</tbody>';
269
  echo '</table>';
270
 
271
- echo '<p class="submit"><input name="Submit" type="submit" class="button-primary" value="' . __( 'Save Changes', 'aws' ) . '" /></p>';
272
 
273
  }
274
 
53
 
54
  case 'text': ?>
55
  <tr valign="top">
56
+ <th scope="row"><?php echo esc_html( $value['name'] ); ?></th>
57
  <td>
58
+ <input type="text" name="<?php echo esc_attr( $value['id'] ); ?>" class="regular-text" value="<?php echo isset( $plugin_options[ $value['id'] ] ) ? esc_attr( stripslashes( $plugin_options[ $value['id'] ] ) ) : ''; ?>">
59
  <br><span class="description"><?php echo $value['desc']; ?></span>
60
  </td>
61
  </tr>
63
 
64
  case 'image': ?>
65
  <tr valign="top">
66
+ <th scope="row"><?php echo esc_html( $value['name'] ); ?></th>
67
  <td>
68
+ <input type="text" name="<?php echo esc_attr( $value['id'] ); ?>" class="regular-text" value="<?php echo esc_attr( stripslashes( $plugin_options[ $value['id'] ] ) ); ?>">
69
  <br><span class="description"><?php echo $value['desc']; ?></span>
70
+ <img style="display: block;max-width: 100px;margin-top: 20px;" src="<?php echo esc_url( $plugin_options[ $value['id'] ] ); ?>">
71
  </td>
72
  </tr>
73
  <?php break;
74
 
75
  case 'number': ?>
76
  <tr valign="top">
77
+ <th scope="row"><?php echo esc_html( $value['name'] ); ?></th>
78
  <td>
79
+ <input type="number" name="<?php echo esc_attr( $value['id'] ); ?>" class="regular-text" value="<?php echo esc_attr( stripslashes( $plugin_options[ $value['id'] ] ) ); ?>">
80
  <br><span class="description"><?php echo $value['desc']; ?></span>
81
  </td>
82
  </tr>
84
 
85
  case 'textarea': ?>
86
  <tr valign="top">
87
+ <th scope="row"><?php echo esc_html( $value['name'] ); ?></th>
88
  <td>
89
+ <textarea id="<?php echo esc_attr( $value['id'] ); ?>" name="<?php echo esc_attr( $value['id'] ); ?>" cols="65" rows="4"><?php print stripslashes( $plugin_options[ $value['id'] ] ); ?></textarea>
90
  <br><span class="description"><?php echo $value['desc']; ?></span>
91
  </td>
92
  </tr>
94
 
95
  case 'checkbox': ?>
96
  <tr valign="top">
97
+ <th scope="row"><?php echo esc_html( $value['name'] ); ?></th>
98
  <td>
99
  <?php $checkbox_options = $plugin_options[ $value['id'] ]; ?>
100
  <?php foreach ( $value['choices'] as $val => $label ) { ?>
101
+ <input type="checkbox" name="<?php echo esc_attr( $value['id'] . '[' . $val . ']' ); ?>" id="<?php echo esc_attr( $value['id'] . '_' . $val ); ?>" value="1" <?php checked( $checkbox_options[$val], '1' ); ?>> <label for="<?php echo esc_attr( $value['id'] . '_' . $val ); ?>"><?php echo esc_html( $label ); ?></label><br>
102
  <?php } ?>
103
  <br><span class="description"><?php echo $value['desc']; ?></span>
104
  </td>
107
 
108
  case 'radio': ?>
109
  <tr valign="top">
110
+ <th scope="row"><?php echo esc_html( $value['name'] ); ?></th>
111
  <td>
112
  <?php foreach ( $value['choices'] as $val => $label ) { ?>
113
+ <input class="radio" type="radio" name="<?php echo esc_attr( $value['id'] ); ?>" id="<?php echo esc_attr( $value['id'].$val ); ?>" value="<?php echo esc_attr( $val ); ?>" <?php checked( $plugin_options[ $value['id'] ], $val ); ?>> <label for="<?php echo esc_attr( $value['id'].$val ); ?>"><?php echo esc_html( $label ); ?></label><br>
114
  <?php } ?>
115
  <br><span class="description"><?php echo $value['desc']; ?></span>
116
  </td>
119
 
120
  case 'select': ?>
121
  <tr valign="top">
122
+ <th scope="row"><?php echo esc_html( $value['name'] ); ?></th>
123
  <td>
124
+ <select name="<?php echo esc_attr( $value['id'] ); ?>">
125
  <?php foreach ( $value['choices'] as $val => $label ) { ?>
126
+ <option value="<?php echo esc_attr( $val ); ?>" <?php selected( $plugin_options[ $value['id'] ], $val ); ?>><?php echo esc_html( $label ); ?></option>
127
  <?php } ?>
128
  </select>
129
  <br><span class="description"><?php echo $value['desc']; ?></span>
133
 
134
  case 'select_advanced': ?>
135
  <tr valign="top">
136
+ <th scope="row"><?php echo esc_html( $value['name'] ); ?></th>
137
  <td>
138
+ <select name="<?php echo esc_attr( $value['id'].'[]' ); ?>" multiple class="chosen-select">
139
  <?php $values = $plugin_options[ $value['id'] ]; ?>
140
  <?php foreach ( $value['choices'] as $val => $label ) { ?>
141
  <?php $selected = ( is_array( $values ) && in_array( $val, $values ) ) ? ' selected="selected" ' : ''; ?>
142
+ <option value="<?php echo esc_attr( $val ); ?>"<?php echo $selected; ?>><?php echo esc_html( $label ); ?></option>
143
  <?php } ?>
144
  </select>
145
  <br><span class="description"><?php echo $value['desc']; ?></span>
148
  <?php $sub_options = $value['sub_option']; ?>
149
  <br><br>
150
  <p>
151
+ <label for="<?php echo esc_attr( $sub_options['id'] ); ?>">
152
+ <input type="checkbox" value="1" id="<?php echo esc_attr( $sub_options['id'] ); ?>" name="<?php echo esc_attr( $sub_options['id'] ); ?>" <?php checked( $plugin_options[ $sub_options['id'] ], '1' ); ?>>
153
+ <?php echo esc_html( $sub_options['desc'] ); ?>
154
  </label>
155
  </p>
156
  <?php endif; ?>
161
 
162
  case 'radio-image': ?>
163
  <tr valign="top">
164
+ <th scope="row"><?php echo esc_html( $value['name'] ); ?></th>
165
  <td>
166
  <ul class="img-select">
167
  <?php foreach ( $value['choices'] as $val => $img ) { ?>
168
  <li class="option">
169
+ <input class="radio" type="radio" name="<?php echo esc_attr( $value['id'] ); ?>" id="<?php echo esc_attr( $value['id'].$val ); ?>" value="<?php echo esc_attr( $val ); ?>" <?php checked( $plugin_options[ $value['id'] ], $val ); ?>>
170
+ <span class="ico" style="background: url('<?php echo esc_url( AWS_URL . '/assets/img/' . $img ); ?>') no-repeat 50% 50%;"></span>
171
  </li>
172
  <?php } ?>
173
  </ul>
178
 
179
  case 'sortable': ?>
180
  <tr valign="top">
181
+ <th scope="row"><?php echo esc_html( $value['name'] ); ?></th>
182
  <td>
183
 
184
  <script>
195
 
196
  });
197
  var serviceListOut = serviceList.substring(1);
198
+ jQuery('#<?php echo esc_attr( $value['id'] ); ?>').attr('value', serviceListOut);
199
  }
200
  }).disableSelection();
201
 
213
  <div class="sortable-container">
214
 
215
  <div class="sortable-title">
216
+ <?php esc_html_e( 'Active sources', 'aws' ) ?><br>
217
+ <?php esc_html_e( 'Change order by drag&drop', 'aws' ) ?>
218
  </div>
219
 
220
  <ul id="sti-sortable2" class="sti-sortable enabled connectedSortable">
222
  if ( count( $active_buttons ) > 0 ) {
223
  foreach ($active_buttons as $button) {
224
  if ( ! $button ) continue;
225
+ echo '<li id="' . esc_attr( $button ) . '" class="sti-btn sti-' . esc_attr( $button ) . '-btn">' . $button . '</li>';
226
  }
227
  }
228
  ?>
233
  <div class="sortable-container">
234
 
235
  <div class="sortable-title">
236
+ <?php esc_html_e( 'Deactivated sources', 'aws' ) ?><br>
237
+ <?php esc_html_e( 'Excluded from search results', 'aws' ) ?>
238
  </div>
239
 
240
  <ul id="sti-sortable1" class="sti-sortable disabled connectedSortable">
241
  <?php
242
  if ( count( $inactive_buttons ) > 0 ) {
243
  foreach ($inactive_buttons as $button) {
244
+ echo '<li id="' . esc_attr( $button ) . '" class="sti-btn sti-' . esc_attr( $button ) . '-btn">' . $button . '</li>';
245
  }
246
  }
247
  ?>
249
 
250
  </div>
251
 
252
+ <input type="hidden" id="<?php echo esc_attr( $value['id'] ); ?>" name="<?php echo esc_attr( $value['id'] ); ?>" value="<?php echo esc_attr( $plugin_options[ $value['id'] ] ); ?>" />
253
 
254
  </td>
255
  </tr>
257
 
258
  case 'heading': ?>
259
  <tr valign="top">
260
+ <th scope="row"><h3 class="aws-heading"><?php echo esc_html( $value['name'] ); ?></h3></th>
261
  </tr>
262
  <?php break;
263
 
268
  echo '</tbody>';
269
  echo '</table>';
270
 
271
+ echo '<p class="submit"><input name="Submit" type="submit" class="button-primary" value="' . esc_attr__( 'Save Changes', 'aws' ) . '" /></p>';
272
 
273
  }
274
 
includes/class-aws-admin.php CHANGED
@@ -56,7 +56,7 @@ class AWS_Admin {
56
  * Add options page
57
  */
58
  public function add_admin_page() {
59
- add_menu_page( __( 'Adv. Woo Search', 'aws' ), __( 'Adv. Woo Search', 'aws' ), 'manage_options', 'aws-options', array( &$this, 'display_admin_page' ), 'dashicons-search' );
60
  }
61
 
62
  /**
@@ -65,14 +65,15 @@ class AWS_Admin {
65
  public function display_admin_page() {
66
 
67
  $options = $this->options_array();
 
68
 
69
  $tabs = array(
70
- 'general' => __( 'General', 'aws' ),
71
- 'form' => __( 'Search Form', 'aws' ),
72
- 'results' => __( 'Search Results', 'aws' )
73
  );
74
 
75
- $current_tab = empty( $_GET['tab'] ) ? 'general' : sanitize_title( $_GET['tab'] );
76
 
77
  $tabs_html = '';
78
 
@@ -81,11 +82,13 @@ class AWS_Admin {
81
 
82
  }
83
 
84
- $tabs_html .= '<a href="https://advanced-woo-search.com/?utm_source=plugin&utm_medium=settings-tab&utm_campaign=aws-pro-plugin" class="nav-tab premium-tab" target="_blank">' . __( 'Get Premium', 'aws' ) . '</a>';
85
 
86
  $tabs_html = '<h2 class="nav-tab-wrapper woo-nav-tab-wrapper">'.$tabs_html.'</h2>';
87
 
88
- if( isset( $_POST["Submit"] ) ) {
 
 
89
  $update_settings = $this->get_settings();
90
 
91
  foreach ( $options[$current_tab] as $values ) {
@@ -100,7 +103,7 @@ class AWS_Admin {
100
 
101
  foreach ( $values['choices'] as $key => $value ) {
102
  $new_value = isset( $_POST[ $values['id'] ][$key] ) ? '1' : '0';
103
- $checkbox_array[$key] = $new_value;
104
  }
105
 
106
  $update_settings[ $values['id'] ] = $checkbox_array;
@@ -109,11 +112,11 @@ class AWS_Admin {
109
  }
110
 
111
  $new_value = isset( $_POST[ $values['id'] ] ) ? $_POST[ $values['id'] ] : '';
112
- $update_settings[ $values['id'] ] = $new_value;
113
 
114
  if ( isset( $values['sub_option'] ) ) {
115
  $new_value = isset( $_POST[ $values['sub_option']['id'] ] ) ? $_POST[ $values['sub_option']['id'] ] : '';
116
- $update_settings[ $values['sub_option']['id'] ] = $new_value;
117
  }
118
  }
119
 
@@ -149,6 +152,8 @@ class AWS_Admin {
149
  new AWS_Admin_Fields( $options['general'] );
150
  }
151
 
 
 
152
  echo '</form>';
153
 
154
  echo '</div>';
@@ -165,15 +170,15 @@ class AWS_Admin {
165
 
166
  echo '<tr>';
167
 
168
- echo '<th>' . __( 'Activation', 'aws' ) . '</th>';
169
  echo '<td>';
170
  echo '<div class="description activation">';
171
- echo __( 'In case you need to add plugin search form on your website, you can do it in several ways:', 'aws' ) . '<br>';
172
  echo '<div class="list">';
173
- echo '1. ' . __( 'Enable a "Seamless integration" option ( may not work with some themes )', 'aws' ) . '<br>';
174
- echo '2. ' . sprintf( __( 'Add search form using shortcode %s', 'aws' ), "<code>[aws_search_form]</code>" ) . '<br>';
175
- echo '3. ' . __( 'Add search form as widget for one of your theme widget areas. Go to Appearance -> Widgets and drag&drop AWS Widget to one of your widget areas', 'aws' ) . '<br>';
176
- echo '4. ' . sprintf( __( 'Add PHP code to the necessary files of your theme: %s', 'aws' ), "<code>&lt;?php if ( function_exists( 'aws_get_search_form' ) ) { aws_get_search_form(); } ?&gt;</code>" ) . '<br>';
177
  echo '</div>';
178
  echo '</div>';
179
  echo '</td>';
@@ -182,13 +187,13 @@ class AWS_Admin {
182
 
183
  echo '<tr>';
184
 
185
- echo '<th>' . __( 'Reindex table', 'aws' ) . '</th>';
186
  echo '<td>';
187
- echo '<div id="aws-reindex"><input class="button" type="button" value="' . __( 'Reindex table', 'aws' ) . '"><span class="loader"></span><span class="reindex-progress">0%</span></div><br><br>';
188
  echo '<span class="description">' .
189
- sprintf( __( 'This action only need for %s one time %s - after you activate this plugin. After this all products changes will be re-indexed automatically.', 'aws' ), '<strong>', '</strong>' ) . '<br>' .
190
  __( 'Update all data in plugins index table. Index table - table with products data where plugin is searching all typed terms.<br>Use this button if you think that plugin not shows last actual data in its search results.<br><strong>CAUTION:</strong> this can take large amount of time.', 'aws' ) . '<br><br>' .
191
- __( 'Products in index:', 'aws' ) . '<span id="aws-reindex-count"> <strong>' . AWS_Helpers::get_indexed_products_count() . '</strong></span>';
192
  echo '</span>';
193
  echo '</td>';
194
 
@@ -197,10 +202,10 @@ class AWS_Admin {
197
 
198
  echo '<tr>';
199
 
200
- echo '<th>' . __( 'Clear cache', 'aws' ) . '</th>';
201
  echo '<td>';
202
- echo '<div id="aws-clear-cache"><input class="button" type="button" value="' . __( 'Clear cache', 'aws' ) . '"><span class="loader"></span></div><br>';
203
- echo '<span class="description">' . __( 'Clear cache for all search results.', 'aws' ) . '</span>';
204
  echo '</td>';
205
 
206
  echo '</tr>';
@@ -249,10 +254,10 @@ class AWS_Admin {
249
  continue;
250
  }
251
 
252
- $default_settings[$values['id']] = $values['value'];
253
 
254
  if (isset( $values['sub_option'])) {
255
- $default_settings[$values['sub_option']['id']] = $values['sub_option']['value'];
256
  }
257
  }
258
  }
@@ -270,7 +275,10 @@ class AWS_Admin {
270
  wp_enqueue_script( 'jquery' );
271
  wp_enqueue_script( 'jquery-ui-sortable' );
272
  wp_enqueue_script( 'plugin-admin-scripts', AWS_URL . '/assets/js/admin.js', array('jquery'), AWS_VERSION );
273
- wp_localize_script( 'plugin-admin-scripts', 'aws_vars', array( 'ajaxurl' => admin_url('admin-ajax.php' ) ) );
 
 
 
274
  }
275
 
276
  }
56
  * Add options page
57
  */
58
  public function add_admin_page() {
59
+ add_menu_page( esc_html__( 'Adv. Woo Search', 'aws' ), esc_html__( 'Adv. Woo Search', 'aws' ), 'manage_options', 'aws-options', array( &$this, 'display_admin_page' ), 'dashicons-search' );
60
  }
61
 
62
  /**
65
  public function display_admin_page() {
66
 
67
  $options = $this->options_array();
68
+ $nonce = wp_create_nonce( 'plugin-settings' );
69
 
70
  $tabs = array(
71
+ 'general' => esc_html__( 'General', 'aws' ),
72
+ 'form' => esc_html__( 'Search Form', 'aws' ),
73
+ 'results' => esc_html__( 'Search Results', 'aws' )
74
  );
75
 
76
+ $current_tab = empty( $_GET['tab'] ) ? 'general' : sanitize_text_field( $_GET['tab'] );
77
 
78
  $tabs_html = '';
79
 
82
 
83
  }
84
 
85
+ $tabs_html .= '<a href="https://advanced-woo-search.com/?utm_source=plugin&utm_medium=settings-tab&utm_campaign=aws-pro-plugin" class="nav-tab premium-tab" target="_blank">' . esc_html__( 'Get Premium', 'aws' ) . '</a>';
86
 
87
  $tabs_html = '<h2 class="nav-tab-wrapper woo-nav-tab-wrapper">'.$tabs_html.'</h2>';
88
 
89
+
90
+ if ( isset( $_POST["Submit"] ) && current_user_can( 'manage_options' ) && isset( $_POST["_wpnonce"] ) && wp_verify_nonce( $_POST["_wpnonce"], 'plugin-settings' ) ) {
91
+
92
  $update_settings = $this->get_settings();
93
 
94
  foreach ( $options[$current_tab] as $values ) {
103
 
104
  foreach ( $values['choices'] as $key => $value ) {
105
  $new_value = isset( $_POST[ $values['id'] ][$key] ) ? '1' : '0';
106
+ $checkbox_array[$key] = (string) sanitize_text_field( $new_value );
107
  }
108
 
109
  $update_settings[ $values['id'] ] = $checkbox_array;
112
  }
113
 
114
  $new_value = isset( $_POST[ $values['id'] ] ) ? $_POST[ $values['id'] ] : '';
115
+ $update_settings[ $values['id'] ] = (string) sanitize_text_field( $new_value );
116
 
117
  if ( isset( $values['sub_option'] ) ) {
118
  $new_value = isset( $_POST[ $values['sub_option']['id'] ] ) ? $_POST[ $values['sub_option']['id'] ] : '';
119
+ $update_settings[ $values['sub_option']['id'] ] = (string) sanitize_text_field( $new_value );
120
  }
121
  }
122
 
152
  new AWS_Admin_Fields( $options['general'] );
153
  }
154
 
155
+ echo '<input type="hidden" name="_wpnonce" value="' . esc_attr( $nonce ) . '">';
156
+
157
  echo '</form>';
158
 
159
  echo '</div>';
170
 
171
  echo '<tr>';
172
 
173
+ echo '<th>' . esc_html__( 'Activation', 'aws' ) . '</th>';
174
  echo '<td>';
175
  echo '<div class="description activation">';
176
+ echo esc_html__( 'In case you need to add plugin search form on your website, you can do it in several ways:', 'aws' ) . '<br>';
177
  echo '<div class="list">';
178
+ echo '1. ' . esc_html__( 'Enable a "Seamless integration" option ( may not work with some themes )', 'aws' ) . '<br>';
179
+ echo '2. ' . sprintf( esc_html__( 'Add search form using shortcode %s', 'aws' ), "<code>[aws_search_form]</code>" ) . '<br>';
180
+ echo '3. ' . esc_html__( 'Add search form as widget for one of your theme widget areas. Go to Appearance -> Widgets and drag&drop AWS Widget to one of your widget areas', 'aws' ) . '<br>';
181
+ echo '4. ' . sprintf( esc_html__( 'Add PHP code to the necessary files of your theme: %s', 'aws' ), "<code>&lt;?php if ( function_exists( 'aws_get_search_form' ) ) { aws_get_search_form(); } ?&gt;</code>" ) . '<br>';
182
  echo '</div>';
183
  echo '</div>';
184
  echo '</td>';
187
 
188
  echo '<tr>';
189
 
190
+ echo '<th>' . esc_html__( 'Reindex table', 'aws' ) . '</th>';
191
  echo '<td>';
192
+ echo '<div id="aws-reindex"><input class="button" type="button" value="' . esc_attr__( 'Reindex table', 'aws' ) . '"><span class="loader"></span><span class="reindex-progress">0%</span></div><br><br>';
193
  echo '<span class="description">' .
194
+ sprintf( esc_html__( 'This action only need for %s one time %s - after you activate this plugin. After this all products changes will be re-indexed automatically.', 'aws' ), '<strong>', '</strong>' ) . '<br>' .
195
  __( 'Update all data in plugins index table. Index table - table with products data where plugin is searching all typed terms.<br>Use this button if you think that plugin not shows last actual data in its search results.<br><strong>CAUTION:</strong> this can take large amount of time.', 'aws' ) . '<br><br>' .
196
+ esc_html__( 'Products in index:', 'aws' ) . '<span id="aws-reindex-count"> <strong>' . AWS_Helpers::get_indexed_products_count() . '</strong></span>';
197
  echo '</span>';
198
  echo '</td>';
199
 
202
 
203
  echo '<tr>';
204
 
205
+ echo '<th>' . esc_html__( 'Clear cache', 'aws' ) . '</th>';
206
  echo '<td>';
207
+ echo '<div id="aws-clear-cache"><input class="button" type="button" value="' . esc_attr__( 'Clear cache', 'aws' ) . '"><span class="loader"></span></div><br>';
208
+ echo '<span class="description">' . esc_html__( 'Clear cache for all search results.', 'aws' ) . '</span>';
209
  echo '</td>';
210
 
211
  echo '</tr>';
254
  continue;
255
  }
256
 
257
+ $default_settings[$values['id']] = (string) sanitize_text_field( $values['value'] );
258
 
259
  if (isset( $values['sub_option'])) {
260
+ $default_settings[$values['sub_option']['id']] = (string) sanitize_text_field( $values['sub_option']['value'] );
261
  }
262
  }
263
  }
275
  wp_enqueue_script( 'jquery' );
276
  wp_enqueue_script( 'jquery-ui-sortable' );
277
  wp_enqueue_script( 'plugin-admin-scripts', AWS_URL . '/assets/js/admin.js', array('jquery'), AWS_VERSION );
278
+ wp_localize_script( 'plugin-admin-scripts', 'aws_vars', array(
279
+ 'ajaxurl' => admin_url('admin-ajax.php' ),
280
+ 'ajax_nonce' => wp_create_nonce( 'aws_admin_ajax_nonce' ),
281
+ ) );
282
  }
283
 
284
  }
includes/class-aws-cache.php CHANGED
@@ -47,15 +47,24 @@ if ( ! class_exists( 'AWS_Cache' ) ) :
47
  $this->cache_table_name = $wpdb->prefix . AWS_CACHE_TABLE_NAME;
48
 
49
  add_action( 'aws_cache_clear', array( $this, 'clear_cache' ) );
50
- add_action( 'wp_ajax_aws-clear-cache', array( $this, 'clear_cache' ) );
51
 
52
  }
53
 
 
 
 
 
 
 
 
 
54
  /**
55
  * Get caching option name
56
  */
57
  public function get_cache_name( $s ) {
58
 
 
59
  $cache_option_name = 'aws_search_term_' . $s;
60
 
61
  if ( has_filter('wpml_current_language') ) {
@@ -117,7 +126,7 @@ if ( ! class_exists( 'AWS_Cache' ) ) :
117
 
118
  $values = $wpdb->prepare(
119
  "(%s, %s)",
120
- $cache_option_name, json_encode( $result_array )
121
  );
122
 
123
  $query = "INSERT IGNORE INTO {$this->cache_table_name}
@@ -143,7 +152,7 @@ if ( ! class_exists( 'AWS_Cache' ) ) :
143
  global $wpdb;
144
 
145
  $result = '';
146
- $where = $wpdb->prepare( " name LIKE %s", $cache_option_name );
147
 
148
  $sql = "SELECT *
149
  FROM
47
  $this->cache_table_name = $wpdb->prefix . AWS_CACHE_TABLE_NAME;
48
 
49
  add_action( 'aws_cache_clear', array( $this, 'clear_cache' ) );
50
+ add_action( 'wp_ajax_aws-clear-cache', array( $this, 'clear_cache_ajax' ) );
51
 
52
  }
53
 
54
+ /*
55
+ * Clear cahce ajax hook
56
+ */
57
+ public function clear_cache_ajax() {
58
+ check_ajax_referer( 'aws_admin_ajax_nonce' );
59
+ $this->clear_cache();
60
+ }
61
+
62
  /**
63
  * Get caching option name
64
  */
65
  public function get_cache_name( $s ) {
66
 
67
+ $s = sanitize_text_field( $s );
68
  $cache_option_name = 'aws_search_term_' . $s;
69
 
70
  if ( has_filter('wpml_current_language') ) {
126
 
127
  $values = $wpdb->prepare(
128
  "(%s, %s)",
129
+ sanitize_text_field( $cache_option_name ), json_encode( $result_array )
130
  );
131
 
132
  $query = "INSERT IGNORE INTO {$this->cache_table_name}
152
  global $wpdb;
153
 
154
  $result = '';
155
+ $where = $wpdb->prepare( " name LIKE %s", sanitize_text_field( $cache_option_name ) );
156
 
157
  $sql = "SELECT *
158
  FROM
includes/class-aws-markup.php CHANGED
@@ -58,10 +58,20 @@ if ( ! class_exists( 'AWS_Markup' ) ) :
58
  'data-use-analytics' => $use_analytics,
59
  'data-min-chars' => $min_chars,
60
  'data-buttons-order' => $buttons_order,
 
61
  );
62
 
 
 
 
 
 
 
 
 
 
63
  foreach( $params as $key => $value ) {
64
- $params_string .= $key . '="' . $value . '" ';
65
  }
66
 
67
  $markup = '';
@@ -70,17 +80,17 @@ if ( ! class_exists( 'AWS_Markup' ) ) :
70
 
71
  $markup .= '<div class="aws-wrapper">';
72
 
73
- $markup .= '<input type="text" name="s" value="' . get_search_query() . '" class="aws-search-field" placeholder="' . $placeholder . '" autocomplete="off" />';
74
  $markup .= '<input type="hidden" name="post_type" value="product">';
75
  $markup .= '<input type="hidden" name="type_aws" value="true">';
76
 
77
  if ( $current_lang ) {
78
- $markup .= '<input type="hidden" name="lang" value="' . $current_lang . '">';
79
  }
80
 
81
  if ( $url_query_parts ) {
82
  foreach( $url_query_parts as $url_query_key => $url_query_value ) {
83
- $markup .= '<input type="hidden" name="' . $url_query_key . '" value="' . $url_query_value . '">';
84
  }
85
  }
86
 
58
  'data-use-analytics' => $use_analytics,
59
  'data-min-chars' => $min_chars,
60
  'data-buttons-order' => $buttons_order,
61
+ 'data-is-mobile' => wp_is_mobile() ? 'true' : 'false',
62
  );
63
 
64
+
65
+ /**
66
+ * Filter form data parameters before output
67
+ * @since 1.69
68
+ * @param array $params Data parameters array
69
+ */
70
+ $params = apply_filters( 'aws_front_data_parameters', $params );
71
+
72
+
73
  foreach( $params as $key => $value ) {
74
+ $params_string .= $key . '="' . esc_attr( $value ) . '" ';
75
  }
76
 
77
  $markup = '';
80
 
81
  $markup .= '<div class="aws-wrapper">';
82
 
83
+ $markup .= '<input type="text" name="s" value="' . get_search_query() . '" class="aws-search-field" placeholder="' . esc_attr( $placeholder ) . '" autocomplete="off" />';
84
  $markup .= '<input type="hidden" name="post_type" value="product">';
85
  $markup .= '<input type="hidden" name="type_aws" value="true">';
86
 
87
  if ( $current_lang ) {
88
+ $markup .= '<input type="hidden" name="lang" value="' . esc_attr( $current_lang ) . '">';
89
  }
90
 
91
  if ( $url_query_parts ) {
92
  foreach( $url_query_parts as $url_query_key => $url_query_value ) {
93
+ $markup .= '<input type="hidden" name="' . esc_attr( $url_query_key ) . '" value="' . esc_attr( $url_query_value ) . '">';
94
  }
95
  }
96
 
includes/class-aws-order.php CHANGED
@@ -60,7 +60,7 @@ if ( ! class_exists( 'AWS_Order' ) ) :
60
  }
61
 
62
  if ( isset( $_GET['rating_filter'] ) && $_GET['rating_filter'] ) {
63
- $rating = explode( ',', $_GET['rating_filter'] );
64
  }
65
 
66
  if ( isset( $query->query_vars['tax_query'] ) ) {
60
  }
61
 
62
  if ( isset( $_GET['rating_filter'] ) && $_GET['rating_filter'] ) {
63
+ $rating = explode( ',', sanitize_text_field( $_GET['rating_filter'] ) );
64
  }
65
 
66
  if ( isset( $query->query_vars['tax_query'] ) ) {
includes/class-aws-search.php CHANGED
@@ -76,7 +76,7 @@ if ( ! class_exists( 'AWS_Search' ) ) :
76
 
77
  global $wpdb;
78
 
79
- $this->lang = isset( $_REQUEST['lang'] ) ? $_REQUEST['lang'] : '';
80
 
81
  if ( $this->lang ) {
82
  do_action( 'wpml_switch_language', $this->lang );
@@ -482,7 +482,7 @@ if ( ! class_exists( 'AWS_Search' ) ) :
482
  $excerpt_length = AWS()->get_settings( 'excerpt_length' );
483
  $mark_search_words = AWS()->get_settings( 'mark_words' );
484
  $show_price = AWS()->get_settings( 'show_price' );
485
- $show_outofstockprice = AWS()->get_settings( 'show_outofstock_price' );
486
  $show_sale = AWS()->get_settings( 'show_sale' );
487
  $show_image = AWS()->get_settings( 'show_image' );
488
  $show_sku = AWS()->get_settings( 'show_sku' );
@@ -571,12 +571,12 @@ if ( ! class_exists( 'AWS_Search' ) ) :
571
  if ( $product->is_in_stock() ) {
572
  $stock_status = array(
573
  'status' => true,
574
- 'text' => __( 'In stock', 'aws' )
575
  );
576
  } else {
577
  $stock_status = array(
578
  'status' => false,
579
- 'text' => __( 'Out of stock', 'aws' )
580
  );
581
  }
582
  }
76
 
77
  global $wpdb;
78
 
79
+ $this->lang = isset( $_REQUEST['lang'] ) ? sanitize_text_field( $_REQUEST['lang'] ) : '';
80
 
81
  if ( $this->lang ) {
82
  do_action( 'wpml_switch_language', $this->lang );
482
  $excerpt_length = AWS()->get_settings( 'excerpt_length' );
483
  $mark_search_words = AWS()->get_settings( 'mark_words' );
484
  $show_price = AWS()->get_settings( 'show_price' );
485
+ $show_outofstockprice = AWS()->get_settings( 'show_outofstock_price' );
486
  $show_sale = AWS()->get_settings( 'show_sale' );
487
  $show_image = AWS()->get_settings( 'show_image' );
488
  $show_sku = AWS()->get_settings( 'show_sku' );
571
  if ( $product->is_in_stock() ) {
572
  $stock_status = array(
573
  'status' => true,
574
+ 'text' => esc_html__( 'In stock', 'aws' )
575
  );
576
  } else {
577
  $stock_status = array(
578
  'status' => false,
579
+ 'text' => esc_html__( 'Out of stock', 'aws' )
580
  );
581
  }
582
  }
includes/class-aws-table.php CHANGED
@@ -48,12 +48,20 @@ if ( ! class_exists( 'AWS_Table' ) ) :
48
 
49
  add_action( 'updated_postmeta', array( $this, 'updated_custom_tabs' ), 10, 4 );
50
 
51
- add_action( 'wp_ajax_aws-reindex', array( $this, 'reindex_table' ) );
52
 
53
  add_action( 'aws_reindex_table', array( $this, 'reindex_table_job' ) );
54
 
55
  }
56
 
 
 
 
 
 
 
 
 
57
  /*
58
  * Reindex plugin table
59
  */
48
 
49
  add_action( 'updated_postmeta', array( $this, 'updated_custom_tabs' ), 10, 4 );
50
 
51
+ add_action( 'wp_ajax_aws-reindex', array( $this, 'reindex_table_ajax' ) );
52
 
53
  add_action( 'aws_reindex_table', array( $this, 'reindex_table_job' ) );
54
 
55
  }
56
 
57
+ /*
58
+ * Reindex plugin table ajax hook
59
+ */
60
+ public function reindex_table_ajax() {
61
+ check_ajax_referer( 'aws_admin_ajax_nonce' );
62
+ $this->reindex_table();
63
+ }
64
+
65
  /*
66
  * Reindex plugin table
67
  */
includes/widget.php CHANGED
@@ -67,7 +67,7 @@ class AWS_Widget extends WP_Widget {
67
  ?>
68
 
69
  <p>
70
- <label for="<?php echo esc_attr( $this->get_field_id('title') ); ?>"><?php _e( 'Title:', 'aws' ); ?></label>
71
  <input type="text" class="widefat" id="<?php echo esc_attr( $this->get_field_id('title') ); ?>" name="<?php echo esc_attr( $this->get_field_name('title') ); ?>" value="<?php echo esc_attr( $instance['title'] ); ?>">
72
  </p>
73
 
67
  ?>
68
 
69
  <p>
70
+ <label for="<?php echo esc_attr( $this->get_field_id('title') ); ?>"><?php esc_html_e( 'Title:', 'aws' ); ?></label>
71
  <input type="text" class="widefat" id="<?php echo esc_attr( $this->get_field_id('title') ); ?>" name="<?php echo esc_attr( $this->get_field_name('title') ); ?>" value="<?php echo esc_attr( $instance['title'] ); ?>">
72
  </p>
73
 
readme.txt CHANGED
@@ -4,7 +4,7 @@ Donate link: https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&hosted_button_i
4
  Tags: widget, plugin, woocommerce, search, product search, woocommerce search, ajax search, live search, custom search, ajax, shortcode, better search, relevance search, relevant search, search by sku, search plugin, shop, store, wordpress search, wp ajax search, wp search, wp search plugin, sidebar, ecommerce, merketing, products, category search, instant-search, search highlight, woocommerce advanced search, woocommerce live search, WooCommerce Plugin, woocommerce product search
5
  Requires at least: 4.0
6
  Tested up to: 5.1
7
- Stable tag: 1.68
8
  License: GPLv2 or later
9
  License URI: http://www.gnu.org/licenses/gpl-2.0.html
10
 
@@ -103,6 +103,10 @@ Yep. This plugin is always compatible with the latest version of Woocommerce?
103
 
104
  == Changelog ==
105
 
 
 
 
 
106
  = 1.68 =
107
  * Update - Styles for plugin settings page
108
  * Dev - Add aws_search_results_tax_archives filter
4
  Tags: widget, plugin, woocommerce, search, product search, woocommerce search, ajax search, live search, custom search, ajax, shortcode, better search, relevance search, relevant search, search by sku, search plugin, shop, store, wordpress search, wp ajax search, wp search, wp search plugin, sidebar, ecommerce, merketing, products, category search, instant-search, search highlight, woocommerce advanced search, woocommerce live search, WooCommerce Plugin, woocommerce product search
5
  Requires at least: 4.0
6
  Tested up to: 5.1
7
+ Stable tag: 1.69
8
  License: GPLv2 or later
9
  License URI: http://www.gnu.org/licenses/gpl-2.0.html
10
 
103
 
104
  == Changelog ==
105
 
106
+ = 1.69 =
107
+ * Dev - Update security checks
108
+ * Dev - Add aws_front_data_parameters filter
109
+
110
  = 1.68 =
111
  * Update - Styles for plugin settings page
112
  * Dev - Add aws_search_results_tax_archives filter