PluginUs.Net - Business Tools for WooCommerce and WordPress

[realize your idea - make your dreams come true]

Support Forum

You need to log-in to create request (topic) to the support

Custom Product Tag Sorting

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 please
If 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.

Hi,

I need to custom sort the product tags in the filter. I tried the solution shown in this thread: https://pluginus.net/support/topic/custom-sort-terms-for-product-tags/   but the product tag order in the filter remains unchanged. I cleared the cache, still no luck.

hello

What plugin  version  number  are  you  using?

For the custom sorting plugin version 3.4.4

For the husky filter, version pro version 3.3.3

Please paste your license key here - https://share.pluginus.net/image/i20230222134241.png -> https://share.pluginus.net/image/i20230222134511.png and  wp-admin access - https://share.pluginus.net/image/i20230222134615.png

Info sent!

Hello

With this user role I can't check anything  - https://share.pluginus.net/image/i20230724113824.png

Updated your access. Please try again.

Hello

Ok!  Please drop  me ftp access -  https://share.pluginus.net/image/i20230222134241.png ->https://share.pluginus.net/image/i20230222134615.png

Sorry, but we don't have FTP access to the server for security reasons.

Hello

I checked on my test site, the taxonomy sort plugin doesn't change the order in the tag.

I wrote a custom solution for you(paste it  on functions.php):

add_filter('woof_sort_terms_before_out', function($terms, $type){
if (count($terms) && 'product_tag' == array_values($terms)[0]['taxonomy']) {
$order = array(31,30,63); // replace with your tag IDs in the correct order
usort($terms, function ($a, $b) use ($order) {
$pos_a = array_search($a['term_id'], $order);
$pos_b = array_search($b['term_id'], $order);
return $pos_a - $pos_b;
});
}
return $terms;
},12,2);

Hi,

I tried the solution, but it's still not working. Can you post the full file location? I want to be sure I'm placing the code on the correct file.

Hello

You can  drop  me  FTP access - https://share.pluginus.net/image/i20230222134241.png ->https://share.pluginus.net/image/i20230222134615.png - I will paste this code