c.schwarzer(@c-schwarzer)
3 Posts
Customers
Quote from c.schwarzer on July 9, 2019, 15:29
Hi,
i want that the user can click on the whole element of a closed filter instead just on the icon.
I have already installed the "Simple Spoiler" Plugin and inserted the shortcode. But the problem is, that I have one Spoiler for the whole filters. I want every filter in one own spoiler.
How is that possible?
Thanks in advance!
Hi,
i want that the user can click on the whole element of a closed filter instead just on the icon.
I have already installed the"Simple Spoiler" Plugin and inserted the shortcode. But the problem is, that I have one Spoiler for the whole filters. I want every filter in one own spoiler.
How is that possible?
Thanks in advance!
Pablo Borysenco(@pavlo_borysenco)
29,363 Posts
Quote from Pablo Borysenco on July 10, 2019, 12:47
Hello
Try this option -
Hello
Try this option -
c.schwarzer(@c-schwarzer)
3 PostsTopic Author
Customers
Quote from c.schwarzer on July 12, 2019, 08:34
Hello,
thank you for the quick reply. That works, but i can only click on the icon instead on the complete background. I think it will be a better user experience, if the user can click on the whole toggled element.
Best regards!
Hello,
thank you for the quick reply. That works, but i can only click on the icon instead on the complete background. I think it will be a better user experience, if the user can click on the whole toggled element.
Best regards!
Pablo Borysenco(@pavlo_borysenco)
29,363 Posts
Quote from Pablo Borysenco on July 12, 2019, 12:29
Hello
In this case you need customize JS
file: path/to/domain/wp-content/plugins/woocommerce-products-filter/js/front.js
1. Finde function woof_init_toggles() and comment it.
2. Then add this function after the previous comment function:
function woof_init_toggles() {
jQuery('.woof_container_inner h4').life('click', function () {
if (jQuery(this).children().data('condition') == 'opened') {
jQuery(this).children().removeClass('woof_front_toggle_opened');
jQuery(this).children().addClass('woof_front_toggle_closed');
jQuery(this).children().data('condition', 'closed');
if (woof_toggle_type == 'text') {
jQuery(this).children().text(woof_toggle_closed_text);
} else {
jQuery(this).children().find('img').prop('src', woof_toggle_closed_image);
}
} else {
jQuery(this).children().addClass('woof_front_toggle_opened');
jQuery(this).children().removeClass('woof_front_toggle_closed');
jQuery(this).children().data('condition', 'opened');
if (woof_toggle_type == 'text') {
jQuery(this).children().text(woof_toggle_opened_text);
} else {
jQuery(this).children().find('img').prop('src', woof_toggle_opened_image);
}
}
jQuery(this).parent().find('.woof_block_html_items').toggle(500);
return false;
});
}
Hello
In this case you need customize JS
file: path/to/domain/wp-content/plugins/woocommerce-products-filter/js/front.js
1. Finde function woof_init_toggles() and comment it.
2. Then add this function after the previous comment function:
function woof_init_toggles() {
jQuery('.woof_container_inner h4').life('click', function () {
if (jQuery(this).children().data('condition') == 'opened') {
jQuery(this).children().removeClass('woof_front_toggle_opened');
jQuery(this).children().addClass('woof_front_toggle_closed');
jQuery(this).children().data('condition', 'closed');
if (woof_toggle_type == 'text') {
jQuery(this).children().text(woof_toggle_closed_text);
} else {
jQuery(this).children().find('img').prop('src', woof_toggle_closed_image);
}
} else {
jQuery(this).children().addClass('woof_front_toggle_opened');
jQuery(this).children().removeClass('woof_front_toggle_closed');
jQuery(this).children().data('condition', 'opened');
if (woof_toggle_type == 'text') {
jQuery(this).children().text(woof_toggle_opened_text);
} else {
jQuery(this).children().find('img').prop('src', woof_toggle_opened_image);
}
}
jQuery(this).parent().find('.woof_block_html_items').toggle(500);
return false;
});
}
c.schwarzer(@c-schwarzer)
3 PostsTopic Author
Customers
Quote from c.schwarzer on July 13, 2019, 07:51
Thank you so much for your help.
I´m sorry to say, but it doesn´t work. I dont see a change on the toggled buttons:
Do you have an idea, what part doesn´t work and how to solve it?
Thanks in advance!
Thank you so much for your help.
I´m sorry to say, but it doesn´t work. I dont see a change on the toggled buttons:
Do you have an idea, what part doesn´t work and how to solve it?
Thanks in advance!
Pablo Borysenco(@pavlo_borysenco)
29,363 Posts
Quote from Pablo Borysenco on July 15, 2019, 12:58
Hello
Please paste your license key here - https://clip2net.com/s/42Aqbg6
Hello
Please paste your license key here - https://clip2net.com/s/42Aqbg6