Version Description
- Fixed: Called to WP_Widget construct
- Fixed: Support to WPML
Download this release
Release Info
Developer | yithemes |
Plugin | YITH WooCommerce Ajax Search |
Version | 1.3.3 |
Comparing to | |
See all releases |
Code changes from version 1.3.2 to 1.3.3
- README.txt +4 -1
- assets/js/frontend.js +2 -3
- assets/js/frontend.min.js +1 -1
- class.yith-wcas.php +1 -0
- init.php +3 -3
- plugin-fw/assets/css/yit-plugin-panel.css +1 -0
- plugin-fw/lib/yit-cpt-unlimited.php +1 -1
- plugin-fw/lib/yit-plugin-common.php +1 -1
- plugin-fw/lib/yit-plugin-panel.php +1 -1
- plugin-fw/lib/yit-plugin-subpanel.php +1 -1
- plugin-fw/templates/metaboxes/types/icon-list.php +2 -2
- widgets/class.yith-wcas-ajax-search.php +2 -3
- wpml-config.xml +6 -0
README.txt
CHANGED
@@ -4,7 +4,7 @@ Contributors: yithemes
|
|
4 |
Tags: ajax, search, woocommerce, products, themes, yit, e-commerce, shop, yith, ajax search, instant search, premium, yithemes, autocomplete, autosuggest, better search, category search, custom search, highlight terms, Live Search, Predictive Search, product search, relevant search, search highlight, search product, suggest, typeahead, WooCommerce Plugin, woocommerce product search, woocommerce search, wordpress ecommerce
|
5 |
Requires at least: 3.5.1
|
6 |
Tested up to: 4.2
|
7 |
-
Stable tag: 1.3.
|
8 |
License: GPLv2 or later
|
9 |
License URI: http://www.gnu.org/licenses/gpl-2.0.html
|
10 |
|
@@ -61,7 +61,10 @@ If you have created your own language pack, or have an update for an existing on
|
|
61 |
2. The plugin at work displaying the ajax search results
|
62 |
|
63 |
== Changelog ==
|
|
|
64 |
|
|
|
|
|
65 |
|
66 |
= 1.3.2 =
|
67 |
|
4 |
Tags: ajax, search, woocommerce, products, themes, yit, e-commerce, shop, yith, ajax search, instant search, premium, yithemes, autocomplete, autosuggest, better search, category search, custom search, highlight terms, Live Search, Predictive Search, product search, relevant search, search highlight, search product, suggest, typeahead, WooCommerce Plugin, woocommerce product search, woocommerce search, wordpress ecommerce
|
5 |
Requires at least: 3.5.1
|
6 |
Tested up to: 4.2
|
7 |
+
Stable tag: 1.3.3
|
8 |
License: GPLv2 or later
|
9 |
License URI: http://www.gnu.org/licenses/gpl-2.0.html
|
10 |
|
61 |
2. The plugin at work displaying the ajax search results
|
62 |
|
63 |
== Changelog ==
|
64 |
+
= 1.3.3 =
|
65 |
|
66 |
+
* Fixed: Called to WP_Widget construct
|
67 |
+
* Fixed: Support to WPML
|
68 |
|
69 |
= 1.3.2 =
|
70 |
|
assets/js/frontend.js
CHANGED
@@ -24,7 +24,6 @@ jQuery(document).ready(function ($) {
|
|
24 |
});
|
25 |
|
26 |
if( el.length == 0 ) el = $('#yith-s');
|
27 |
-
|
28 |
el.each(function () {
|
29 |
var $t = $(this),
|
30 |
append_to = ( typeof $t.data('append-to') == 'undefined') ? $t.closest('.yith-ajaxsearchform-container') : $t.data('append-to');
|
@@ -34,7 +33,7 @@ jQuery(document).ready(function ($) {
|
|
34 |
appendTo : append_to,
|
35 |
serviceUrl : woocommerce_params.ajax_url + '?action=yith_ajax_search_products',
|
36 |
onSearchStart : function () {
|
37 |
-
$
|
38 |
},
|
39 |
onSelect : function (suggestion) {
|
40 |
if (suggestion.id != -1) {
|
@@ -42,7 +41,7 @@ jQuery(document).ready(function ($) {
|
|
42 |
}
|
43 |
} ,
|
44 |
onSearchComplete: function () {
|
45 |
-
$t.css('background', '
|
46 |
}
|
47 |
});
|
48 |
});
|
24 |
});
|
25 |
|
26 |
if( el.length == 0 ) el = $('#yith-s');
|
|
|
27 |
el.each(function () {
|
28 |
var $t = $(this),
|
29 |
append_to = ( typeof $t.data('append-to') == 'undefined') ? $t.closest('.yith-ajaxsearchform-container') : $t.data('append-to');
|
33 |
appendTo : append_to,
|
34 |
serviceUrl : woocommerce_params.ajax_url + '?action=yith_ajax_search_products',
|
35 |
onSearchStart : function () {
|
36 |
+
$t.css({'background-image': 'url(' + loader_icon + ')','background-repeat': 'no-repeat', 'background-position': 'center right'});
|
37 |
},
|
38 |
onSelect : function (suggestion) {
|
39 |
if (suggestion.id != -1) {
|
41 |
}
|
42 |
} ,
|
43 |
onSearchComplete: function () {
|
44 |
+
$t.css('background-image', 'none');
|
45 |
}
|
46 |
});
|
47 |
});
|
assets/js/frontend.min.js
CHANGED
@@ -1,2 +1,2 @@
|
|
1 |
jQuery(document).ready(function(b){var a=b(".yith-s"),c="undefined"!=typeof woocommerce_params&&"undefined"!=typeof woocommerce_params.ajax_loader_url?woocommerce_params.ajax_loader_url:yith_wcas_params.loading,e=""==a.data("loader-icon")?c:a.data("loader-icon"),c=b("#yith-searchsubmit"),f=a.data("min-chars");c.on("click",function(){return""==b(this).closest("form").find(".yith-s").val()?!1:!0});0==a.length&&(a=b("#yith-s"));a.each(function(){var d=b(this),c="undefined"==typeof d.data("append-to")?
|
2 |
-
d.closest(".yith-ajaxsearchform-container"):d.data("append-to");a.yithautocomplete({minChars:f,appendTo:c,serviceUrl:woocommerce_params.ajax_url+"?action=yith_ajax_search_products",onSearchStart:function(){
|
1 |
jQuery(document).ready(function(b){var a=b(".yith-s"),c="undefined"!=typeof woocommerce_params&&"undefined"!=typeof woocommerce_params.ajax_loader_url?woocommerce_params.ajax_loader_url:yith_wcas_params.loading,e=""==a.data("loader-icon")?c:a.data("loader-icon"),c=b("#yith-searchsubmit"),f=a.data("min-chars");c.on("click",function(){return""==b(this).closest("form").find(".yith-s").val()?!1:!0});0==a.length&&(a=b("#yith-s"));a.each(function(){var d=b(this),c="undefined"==typeof d.data("append-to")?
|
2 |
+
d.closest(".yith-ajaxsearchform-container"):d.data("append-to");a.yithautocomplete({minChars:f,appendTo:c,serviceUrl:woocommerce_params.ajax_url+"?action=yith_ajax_search_products",onSearchStart:function(){d.css({"background-image":"url("+e+")","background-repeat":"no-repeat","background-position":"center right"})},onSelect:function(a){-1!=a.id&&(window.location.href=a.url)},onSearchComplete:function(){d.css("background-image","none")}})})});
|
class.yith-wcas.php
CHANGED
@@ -135,6 +135,7 @@ if ( !class_exists( 'YITH_WCAS' ) ) {
|
|
135 |
'orderby' => $ordering_args['orderby'],
|
136 |
'order' => $ordering_args['order'],
|
137 |
'posts_per_page' => apply_filters( 'yith_wcas_ajax_search_products_posts_per_page', get_option( 'yith_wcas_posts_per_page' ) ),
|
|
|
138 |
'meta_query' => array(
|
139 |
array(
|
140 |
'key' => '_visibility',
|
135 |
'orderby' => $ordering_args['orderby'],
|
136 |
'order' => $ordering_args['order'],
|
137 |
'posts_per_page' => apply_filters( 'yith_wcas_ajax_search_products_posts_per_page', get_option( 'yith_wcas_posts_per_page' ) ),
|
138 |
+
'suppress_filters' => false,
|
139 |
'meta_query' => array(
|
140 |
array(
|
141 |
'key' => '_visibility',
|
init.php
CHANGED
@@ -3,7 +3,7 @@
|
|
3 |
* Plugin Name: YITH WooCommerce Ajax Search
|
4 |
* Plugin URI: http://yithemes.com/
|
5 |
* Description: YITH WooCommerce Ajax Search allows your users to search products in real time.
|
6 |
-
* Version: 1.3.
|
7 |
* Author: Yithemes
|
8 |
* Author URI: http://yithemes.com/
|
9 |
* Text Domain: yit
|
@@ -59,7 +59,7 @@ register_activation_hook( __FILE__, 'yith_plugin_registration_hook' );
|
|
59 |
if ( defined( 'YITH_WCAS_VERSION' ) ){
|
60 |
return;
|
61 |
}else{
|
62 |
-
define( 'YITH_WCAS_VERSION', '1.3.
|
63 |
}
|
64 |
|
65 |
if ( ! defined( 'YITH_WCAS_FREE_INIT' ) ) {
|
@@ -101,7 +101,7 @@ function yith_ajax_search_constructor() {
|
|
101 |
function yith_wcas_install_woocommerce_admin_notice() {
|
102 |
?>
|
103 |
<div class="error">
|
104 |
-
<p><?php _e( 'YITH WooCommerce Ajax Search is enabled but not effective. It requires
|
105 |
</div>
|
106 |
<?php
|
107 |
}
|
3 |
* Plugin Name: YITH WooCommerce Ajax Search
|
4 |
* Plugin URI: http://yithemes.com/
|
5 |
* Description: YITH WooCommerce Ajax Search allows your users to search products in real time.
|
6 |
+
* Version: 1.3.3
|
7 |
* Author: Yithemes
|
8 |
* Author URI: http://yithemes.com/
|
9 |
* Text Domain: yit
|
59 |
if ( defined( 'YITH_WCAS_VERSION' ) ){
|
60 |
return;
|
61 |
}else{
|
62 |
+
define( 'YITH_WCAS_VERSION', '1.3.3' );
|
63 |
}
|
64 |
|
65 |
if ( ! defined( 'YITH_WCAS_FREE_INIT' ) ) {
|
101 |
function yith_wcas_install_woocommerce_admin_notice() {
|
102 |
?>
|
103 |
<div class="error">
|
104 |
+
<p><?php _e( 'YITH WooCommerce Ajax Search is enabled but not effective. It requires WooCommerce in order to work.', 'yit' ); ?></p>
|
105 |
</div>
|
106 |
<?php
|
107 |
}
|
plugin-fw/assets/css/yit-plugin-panel.css
CHANGED
@@ -169,6 +169,7 @@
|
|
169 |
padding-left: 6px;
|
170 |
position: absolute;
|
171 |
z-index: 2;
|
|
|
172 |
}
|
173 |
.ie8 .yit_options select,
|
174 |
.ie8 .yit-options select {
|
169 |
padding-left: 6px;
|
170 |
position: absolute;
|
171 |
z-index: 2;
|
172 |
+
overflow: hidden;
|
173 |
}
|
174 |
.ie8 .yit_options select,
|
175 |
.ie8 .yit-options select {
|
plugin-fw/lib/yit-cpt-unlimited.php
CHANGED
@@ -1630,7 +1630,7 @@ class YIT_CPT_Unlimited {
|
|
1630 |
class: 'multi-uploader add-new-h2',
|
1631 |
'data-uploader_title': '<?php printf( __( 'Add %s from images', 'yith-plugin-fw' ), $label_plural ) ?>',
|
1632 |
'data-uploader_button_text': '<?php printf( __( 'Add %s', 'yith-plugin-fw' ), $label_plural ) ?>'
|
1633 |
-
}).text('<?php _e( '
|
1634 |
|
1635 |
var spinner = $('<span />', {
|
1636 |
class: 'spinner',
|
1630 |
class: 'multi-uploader add-new-h2',
|
1631 |
'data-uploader_title': '<?php printf( __( 'Add %s from images', 'yith-plugin-fw' ), $label_plural ) ?>',
|
1632 |
'data-uploader_button_text': '<?php printf( __( 'Add %s', 'yith-plugin-fw' ), $label_plural ) ?>'
|
1633 |
+
}).text('<?php _e( 'Upload multiple files', 'yith-plugin-fw' ) ?>');
|
1634 |
|
1635 |
var spinner = $('<span />', {
|
1636 |
class: 'spinner',
|
plugin-fw/lib/yit-plugin-common.php
CHANGED
@@ -27,7 +27,7 @@ class YIT_Plugin_Common {
|
|
27 |
|
28 |
|
29 |
'awesome_icons' => array(
|
30 |
-
'' => '
|
31 |
'f042' => 'adjust',
|
32 |
'f170' => 'adn',
|
33 |
'f037' => 'align-center',
|
27 |
|
28 |
|
29 |
'awesome_icons' => array(
|
30 |
+
'' => 'no-icon',
|
31 |
'f042' => 'adjust',
|
32 |
'f170' => 'adn',
|
33 |
'f037' => 'align-center',
|
plugin-fw/lib/yit-plugin-panel.php
CHANGED
@@ -295,7 +295,7 @@ if ( ! class_exists( 'YIT_Plugin_Panel' ) ) {
|
|
295 |
<form method="post">
|
296 |
<?php $warning = __( 'If you continue with this action, you will reset all options in this page.', 'yith-plugin-fw' ) ?>
|
297 |
<input type="hidden" name="yit-action" value="reset" />
|
298 |
-
<input type="submit" name="yit-reset" class="button-secondary" value="<?php _e( 'Reset to
|
299 |
</form>
|
300 |
<p> </p>
|
301 |
<?php endif ?>
|
295 |
<form method="post">
|
296 |
<?php $warning = __( 'If you continue with this action, you will reset all options in this page.', 'yith-plugin-fw' ) ?>
|
297 |
<input type="hidden" name="yit-action" value="reset" />
|
298 |
+
<input type="submit" name="yit-reset" class="button-secondary" value="<?php _e( 'Reset to default', 'yith-plugin-fw' ) ?>" onclick="return confirm('<?php echo $warning . '\n' . __( 'Are you sure?', 'yith-plugin-fw' ) ?>');" />
|
299 |
</form>
|
300 |
<p> </p>
|
301 |
<?php endif ?>
|
plugin-fw/lib/yit-plugin-subpanel.php
CHANGED
@@ -145,7 +145,7 @@ if ( ! class_exists( 'YIT_Plugin_SubPanel' ) ) {
|
|
145 |
<form method="post">
|
146 |
<?php $warning = __( 'If you continue with this action, you will reset all the options in this page.', 'yith-plugin-fw' ) ?>
|
147 |
<input type="hidden" name="yit-action" value="reset" />
|
148 |
-
<input type="submit" name="yit-reset" class="button-secondary" value="<?php _e( 'Reset to
|
149 |
</form>
|
150 |
<p> </p>
|
151 |
<?php endif ?>
|
145 |
<form method="post">
|
146 |
<?php $warning = __( 'If you continue with this action, you will reset all the options in this page.', 'yith-plugin-fw' ) ?>
|
147 |
<input type="hidden" name="yit-action" value="reset" />
|
148 |
+
<input type="submit" name="yit-reset" class="button-secondary" value="<?php _e( 'Reset to default', 'yith-plugin-fw' ) ?>" onclick="return confirm('<?php echo $warning . '\n' . __( 'Are you sure?', 'yith-plugin-fw' ) ?>');" />
|
149 |
</form>
|
150 |
<p> </p>
|
151 |
<?php endif ?>
|
plugin-fw/templates/metaboxes/types/icon-list.php
CHANGED
@@ -23,7 +23,7 @@ if ( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly
|
|
23 |
|
24 |
$current_options = wp_parse_args( $args['value'], $args['std'] );
|
25 |
$current_icon = YIT_Icon()->get_icon_data( $current_options['icon'] );
|
26 |
-
$
|
27 |
|
28 |
$options['icon'] = YIT_Plugin_Common::get_icon_list();
|
29 |
|
@@ -88,7 +88,7 @@ $options['icon'] = YIT_Plugin_Common::get_icon_list();
|
|
88 |
<?php if( $std['select'] == 'custom' ) : ?>
|
89 |
<?php printf( __( '(Default: %s <img src="%s"/>)', 'yith-plugin-fw' ), $options['select']['custom'], $std['custom'] ) ?>
|
90 |
<?php else: ?>
|
91 |
-
<?php printf( __( '(Default: <i %s></i> )', 'yith-plugin-fw' ), $
|
92 |
<?php endif; ?>
|
93 |
</div>
|
94 |
|
23 |
|
24 |
$current_options = wp_parse_args( $args['value'], $args['std'] );
|
25 |
$current_icon = YIT_Icon()->get_icon_data( $current_options['icon'] );
|
26 |
+
$std_icon = YIT_Icon()->get_icon_data( $std['icon'] );
|
27 |
|
28 |
$options['icon'] = YIT_Plugin_Common::get_icon_list();
|
29 |
|
88 |
<?php if( $std['select'] == 'custom' ) : ?>
|
89 |
<?php printf( __( '(Default: %s <img src="%s"/>)', 'yith-plugin-fw' ), $options['select']['custom'], $std['custom'] ) ?>
|
90 |
<?php else: ?>
|
91 |
+
<?php printf( __( '(Default: <i %s></i> )', 'yith-plugin-fw' ), $std_icon ) ?>
|
92 |
<?php endif; ?>
|
93 |
</div>
|
94 |
|
widgets/class.yith-wcas-ajax-search.php
CHANGED
@@ -20,9 +20,8 @@ if( !class_exists( 'YITH_WCAS_Ajax_Search_Widget' ) ) {
|
|
20 |
* constructor
|
21 |
*
|
22 |
* @access public
|
23 |
-
* @return void
|
24 |
*/
|
25 |
-
function
|
26 |
|
27 |
/* Widget variable settings. */
|
28 |
$this->woo_widget_cssclass = 'woocommerce widget_product_search yith_woocommerce_ajax_search';
|
@@ -34,7 +33,7 @@ if( !class_exists( 'YITH_WCAS_Ajax_Search_Widget' ) ) {
|
|
34 |
$widget_ops = array( 'classname' => $this->woo_widget_cssclass, 'description' => $this->woo_widget_description );
|
35 |
|
36 |
/* Create the widget. */
|
37 |
-
|
38 |
}
|
39 |
|
40 |
|
20 |
* constructor
|
21 |
*
|
22 |
* @access public
|
|
|
23 |
*/
|
24 |
+
function __construct() {
|
25 |
|
26 |
/* Widget variable settings. */
|
27 |
$this->woo_widget_cssclass = 'woocommerce widget_product_search yith_woocommerce_ajax_search';
|
33 |
$widget_ops = array( 'classname' => $this->woo_widget_cssclass, 'description' => $this->woo_widget_description );
|
34 |
|
35 |
/* Create the widget. */
|
36 |
+
parent::__construct('yith_woocommerce_ajax_search', $this->woo_widget_name, $widget_ops);
|
37 |
}
|
38 |
|
39 |
|
wpml-config.xml
ADDED
@@ -0,0 +1,6 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<wpml-config>
|
2 |
+
<admin-texts>
|
3 |
+
<key name="yith_wcas_search_input_label">
|
4 |
+
<key name="yith_wcas_search_submit_label">
|
5 |
+
</admin-texts>
|
6 |
+
</wpml-config>
|