Home › Forums › WoodMart support forum › Woodmart elementor widgets issue
Woodmart elementor widgets issue
- This topic has 4 replies, 2 voices, and was last updated 1 month, 4 weeks ago by
Hung Pham.
-
AuthorPosts
-
May 16, 2025 at 7:03 pm #661283
[email protected]ParticipantWe are facing a big issue with the woodmart elementor widgets.
When we try to choose which taxonomies we’d like to show on a products carousel, or an AJAX products tab, the result is always “No results”.
Searching for whatever term of whatever taxonomy, nothing is found.
If we use the generic elementor widget for products, it returns the taxonomies as it should.
The only plugins left on the site right now is Woocommerce and Elementor.
Everything else is deactivated.-
This topic was modified 2 months ago by
[email protected].
May 17, 2025 at 2:21 pm #661362
Hung PhamKeymasterHello [email protected],
Thanks for reaching to us.
Could you please record a short video and describe how we can reproduce the issue on your website so we can check this for you?
Thanks for your patience.
Regards,
May 17, 2025 at 2:46 pm #661369
[email protected]ParticipantHere is the video you requested:
http://staging.callofbeautypro.com/wp-content/uploads/2025/05/woodmart.mp4
As you can see, no matter the term we search for in the woodmart widget, no results are returned.
This may be a staging site, but the live site has the same issue and the client is requesting some changes but we’re unable to proceed with those due to this issue.
So it is kind of urgent for us and we’d appreciate an immediate response.
Thank you in advance.
May 19, 2025 at 3:05 am #661482
Hung PhamKeymasterHello [email protected],
I’ve passed this topic to one of our developers, and I will let you know once get an answer.
Thanks for your patience.
Best Regards,
May 19, 2025 at 5:36 pm #661672
Hung PhamKeymasterHello [email protected],
Try to use the code below instead of yours. Define the code in the functions.php file in your child theme.
function woodmart_get_taxonomies_by_query() { $search_string = isset( $_POST['q'] ) ? sanitize_text_field( wp_unslash( $_POST['q'] ) ) : ''; // phpcs:ignore $taxonomy = isset( $_POST['taxonomy'] ) ? $_POST['taxonomy'] : ''; // phpcs:ignore $results = array(); if ( is_array( $taxonomy ) ) { $taxonomy = array_filter( $taxonomy, function( $tax ) { return taxonomy_exists( $tax ); } ); } $args = array( 'taxonomy' => $taxonomy, 'hide_empty' => false, 'search' => $search_string, ); $terms = get_terms( $args ); if ( is_array( $terms ) && $terms ) { foreach ( $terms as $term ) { if ( is_object( $term ) ) { $results[] = array( 'id' => $term->term_id, 'text' => $term->name . ' (' . $term->taxonomy . ')', ); } } } wp_send_json( $results ); } add_action( 'wp_ajax_woodmart_get_taxonomies_by_query', 'woodmart_get_taxonomies_by_query' ); add_action( 'wp_ajax_nopriv_woodmart_get_taxonomies_by_query', 'woodmart_get_taxonomies_by_query' );
Regards,
-
This topic was modified 2 months ago by
-
AuthorPosts
- You must be logged in to create new topics. Login / Register