After activating HUSKY and using php code to make product grid searchable only 10 products are found front-end and back-end
The support doesn work on Saturdays and Sundays, so some Friday requests can be answered on Monday. If you have problems with registration ask help on contact us page pleaseIf you not got email within 24~36 business hours, firstly check your spam box, and if no any email from the support there - back to the forum and read answer here. DO NOT ANSWER ON EMAILS [noreply@pluginus.net] FROM THE FORUM!! Emails are just for your info, all answers should be published only here.
The support doesn work on Saturdays and Sundays, so some Friday requests can be answered on Monday.
Quote from fdstill on March 4, 2024, 12:06I use Divi theme with a child theme and have a customized shop page.
In order to make this customized product grid searchable I added the following php in my childs theme functions.php:
//Make the Husky product filter work with page builder layouts
add_action(‘pre_get_posts’, function ($query) {
if (is_object($query) AND isset($query->query[‘post_type’])) {
if ($query->query[‘post_type’] === ‘product’ /* AND is_page(1867) */) {
if (isset($query->query[‘wc_query’]) AND ‘product_query’ == $query->query[‘wc_query’]) {
return $query;
}global $WOOF;
if (is_object($WOOF) AND !empty(woof()->get_request_data())) {
woof()->woof_products_ids_prediction(true);
$query->query_vars[‘post__in’] = $_REQUEST[‘woof_wp_query_ids’];
}
}
}return $query;
});
Before I make a product search on the front-end, I can go through all my products. As soon as I HUSKY search (front-end) I get the right search results but with a maximum of 10 products and no possibility to use pagination.
Another strange occurrence: When I look at my products in the back-end, it also only shows 10 products (the tabs show: ‘all (212)’|published (207)|…)
As soon as I delete the php function, the problem disappears, but my product grid is not searchable anymore.
Please help!
I use Divi theme with a child theme and have a customized shop page.
In order to make this customized product grid searchable I added the following php in my childs theme functions.php:
//Make the Husky product filter work with page builder layouts
add_action(‘pre_get_posts’, function ($query) {
if (is_object($query) AND isset($query->query[‘post_type’])) {
if ($query->query[‘post_type’] === ‘product’ /* AND is_page(1867) */) {
if (isset($query->query[‘wc_query’]) AND ‘product_query’ == $query->query[‘wc_query’]) {
return $query;
}global $WOOF;
if (is_object($WOOF) AND !empty(woof()->get_request_data())) {
woof()->woof_products_ids_prediction(true);
$query->query_vars[‘post__in’] = $_REQUEST[‘woof_wp_query_ids’];
}
}
}return $query;
});
Before I make a product search on the front-end, I can go through all my products. As soon as I HUSKY search (front-end) I get the right search results but with a maximum of 10 products and no possibility to use pagination.
Another strange occurrence: When I look at my products in the back-end, it also only shows 10 products (the tabs show: ‘all (212)’|published (207)|…)
As soon as I delete the php function, the problem disappears, but my product grid is not searchable anymore.
Please help!
Quote from Pablo Borysenco on March 4, 2024, 13:39Hello
Please drop me exact link to the issue
Hello
Please drop me exact link to the issue
Quote from fdstill on March 4, 2024, 13:40www.stilomio.com
Quote from fdstill on March 5, 2024, 10:34to be precise:
stilomio.com/shop
to be precise:
stilomio.com/shop
Quote from Pablo Borysenco on March 5, 2024, 12:38Hello
Please paste your license key here - https://share.pluginus.net/image/i20230222134241.png -> https://share.pluginus.net/image/i20230222134511.png and wp-admin+ftp access - https://share.pluginus.net/image/i20230222134615.png
Update the plugin to latest version - https://products-filter.com/how-to-make-auto-update-for-wordpress-plugins-and-themes-bought-on-envato
Hello
Please paste your license key here - https://share.pluginus.net/image/i20230222134241.png -> https://share.pluginus.net/image/i20230222134511.png and wp-admin+ftp access - https://share.pluginus.net/image/i20230222134615.png
Update the plugin to latest version - https://products-filter.com/how-to-make-auto-update-for-wordpress-plugins-and-themes-bought-on-envato
Quote from fdstill on March 6, 2024, 12:28everything uploaded!
everything uploaded!
Quote from Pablo Borysenco on March 7, 2024, 14:13Hello
Please do a test
Hello
Please do a test
Quote from fdstill on March 8, 2024, 10:34Hi Pablo,
it is still not working properly. All products are shown in the backend, but the following problems remain:
- the search results are usually only correct on page 1
- if you search for earrings + 23k gold plated you get necklaces, rings and bracelets at page 2 and following
- the breadcrumbs or search terms are not shown above the search results
- "Ohrstecker" and "Ohrclips" are subcategories of "Ohrringe" but they are not indented as they used to be
Please help!
Thanks
Fred
Hi Pablo,
it is still not working properly. All products are shown in the backend, but the following problems remain:
- the search results are usually only correct on page 1
- if you search for earrings + 23k gold plated you get necklaces, rings and bracelets at page 2 and following
- the breadcrumbs or search terms are not shown above the search results
- "Ohrstecker" and"Ohrclips" are subcategories of"Ohrringe" but they are not indented as they used to be
Please help!
Thanks
Fred
Quote from Pablo Borysenco on March 8, 2024, 12:36hello
1) Please remove ajax pagination
2) give me a link where the breadcrumbs are displayed. I don't see this on your site
3) looks like these are your custom styles - https://share.pluginus.net/video/v20240308123535.mp4
hello
1) Please remove ajax pagination
2) give me a link where the breadcrumbs are displayed. I don't see this on your site
3) looks like these are your custom styles - https://share.pluginus.net/video/v20240308123535.mp4
Quote from fdstill on March 12, 2024, 12:02Hi Pablo,
now it shows all products at the product section of the back-end. But the search still doesn't work. I tried to remove ajax pagination (globally and individually on the page -> still not working).
It really drives me crazy, please help!
Thanks
Fred
Hi Pablo,
now it shows all products at the product section of the back-end. But the search still doesn't work. I tried to remove ajax pagination (globally and individually on the page -> still not working).
It really drives me crazy, please help!
Thanks
Fred
Quote from Pablo Borysenco on March 12, 2024, 13:09Hello Fred
I tried to remove ajax pagination - These are the product template settings; unfortunately, I don’t know how to disable the ajax mode in third-party functionality. But filtering will not work with third-party ajax pagination because it is a separate request to the database without taking into account search queries
Hello Fred
I tried to remove ajax pagination - These are the product template settings; unfortunately, I don’t know how to disable the ajax mode in third-party functionality. But filtering will not work with third-party ajax pagination because it is a separate request to the database without taking into account search queries