We needed to create a filter that shows a hierarchical list of countries and cities and unfortunately the current filters doesn't display the taxonomy terms in such an order to show children under parents but rather displays a plain list of terms. To solve our issue we've had to modify the following core file ( wp-content/plugins/eventON/includes/calendar/class-calendar-filtering.php:192 ) and implement a new hook:
evo_get_frontend_filter_tax_{{taxonomy}}_terms
Here is the modified code that I'm using right now in production:
$cats = apply_filters( 'evo_get_frontend_filter_tax_'.$vv.'_terms', get_terms( apply_filters('evo_get_frontend_filter_tax',
array( 'taxonomy'=> $vv,'hide_empty'=> false, )
)));
Would be good if you can add this as soon as possible so I can keep my plugins updated without core files modifications.
Thank you!
- Jun 3,2024 AT 4:17AM - 2 years ago