Price Filter doesnt change max price
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 myst3k on March 2, 2023, 18:31Hello,
The price filter pulls up the correct products based on the price selected, and the category selected, however the Max Price doesn't change based on the category selected Can you please help point me in the right direction?
I have tried enabling SEO URL Request, and Advanced Searching by Text. I have Optimize Price Filter disabled now due to testing.
Thanks
Hello,
The price filter pulls up the correct products based on the price selected, and the category selected, however the Max Price doesn't change based on the category selected Can you please help point me in the right direction?
I have tried enabling SEO URL Request, and Advanced Searching by Text. I have Optimize Price Filter disabled now due to testing.
Thanks
Quote from myst3k on March 2, 2023, 20:14Right now I am using the default settings and no hooks trying to get the price to update based on the category selected.
However my end goal is to make the price take the maximum value, of all of the lowest price variations.
The current MAX Price displayed is $2201 since there are box sets. The slider is kind of useless right now.
After messing around with something like this in the hook. I can get the maximum of the lowest price variations, which turns out to be $406.
$sql = "SELECT min(FLOOR(price_meta.meta_value + 0.0)) AS min_price,";
$sql .= " MAX(CEIL( ";
$sql .= " (SELECT MIN(CEIL(pm2.meta_value + 0.0)) AS mvp ";
$sql .= " FROM wp_posts wp2 ";
$sql .= " LEFT JOIN wp_postmeta AS pm2 ON wp2.ID = pm2.post_id ";
$sql .= " WHERE wp2.ID = wp_posts.ID ";
$sql .= " AND pm2.meta_key IN ('_price') ";
$sql .= " LIMIT 1) + 0.0)) AS max_price ";
$sql .= "FROM wp_posts ";
$sql .= "LEFT JOIN wp_postmeta AS price_meta ON wp_posts.ID = price_meta.post_id ";
$sql .= "WHERE wp_posts.post_type = 'product' ";
$sql .= " AND wp_posts.post_status = 'publish' ";
$sql .= " AND price_meta.meta_value > '' ";
$sql .= " AND price_meta.meta_key IN ('_price') ";
Right now I am using the default settings and no hooks trying to get the price to update based on the category selected.
However my end goal is to make the price take the maximum value, of all of the lowest price variations.
The current MAX Price displayed is $2201 since there are box sets. The slider is kind of useless right now.
After messing around with something like this in the hook. I can get the maximum of the lowest price variations, which turns out to be $406.
$sql ="SELECT min(FLOOR(price_meta.meta_value + 0.0)) AS min_price,";
$sql .=" MAX(CEIL(";
$sql .=" (SELECT MIN(CEIL(pm2.meta_value + 0.0)) AS mvp";
$sql .=" FROM wp_posts wp2";
$sql .=" LEFT JOIN wp_postmeta AS pm2 ON wp2.ID = pm2.post_id";
$sql .=" WHERE wp2.ID = wp_posts.ID";
$sql .=" AND pm2.meta_key IN ('_price')";
$sql .=" LIMIT 1) + 0.0)) AS max_price";
$sql .="FROM wp_posts";
$sql .="LEFT JOIN wp_postmeta AS price_meta ON wp_posts.ID = price_meta.post_id";
$sql .="WHERE wp_posts.post_type = 'product'";
$sql .=" AND wp_posts.post_status = 'publish'";
$sql .=" AND price_meta.meta_value > ''";
$sql .=" AND price_meta.meta_key IN ('_price')";
Quote from Pablo Borysenco on March 3, 2023, 11:30Hello
Please drop me exact link to the issue
Hello
Please drop me exact link to the issue
Quote from myst3k on March 3, 2023, 15:39https://smokemanayunk.com/shop/
If you land and the main shop page, the min/max prices for the slider are 0-2201.
When you make changes to the filters, the max price stays at 2201 instead of changing to the max value for the selected items.
Plugin Version: 3.3.2
https://smokemanayunk.com/shop/
If you land and the main shop page, the min/max prices for the slider are 0-2201.
When you make changes to the filters, the max price stays at 2201 instead of changing to the max value for the selected items.
Plugin Version: 3.3.2
Quote from Pablo Borysenco on March 6, 2023, 12:19Hello
Please paste your license key here - https://share.pluginus.net/image/i20230222134241.png -> https://share.pluginus.net/image/i20230222134511.png
Hello
Please paste your license key here - https://share.pluginus.net/image/i20230222134241.png -> https://share.pluginus.net/image/i20230222134511.png
Quote from Pablo Borysenco on March 7, 2023, 15:12Hello
Please try in file - wp-content\plugins\woocommerce-products-filter\classes\helper.php - change this code - https://share.pluginus.net/image/i20230307151142.png
$tax_query = woof()->get_tax_query($additional_taxes);
and do a test
Hello
Please try in file - wp-content\plugins\woocommerce-products-filter\classes\helper.php - change this code - https://share.pluginus.net/image/i20230307151142.png
$tax_query = woof()->get_tax_query($additional_taxes);
and do a test
Quote from myst3k on March 7, 2023, 15:58After changing that line, the filter properly updated the prices when changing categories!
After changing that line, the filter properly updated the prices when changing categories!
Quote from Pablo Borysenco on March 8, 2023, 11:29Great! Welcome;)
We will add this to the new version of the plugin
Great! Welcome;)
We will add this to the new version of the plugin
Quote from myst3k on March 8, 2023, 16:44Thank you for the help, that is great news!
Thank you for the help, that is great news!