Skip Navigation

[Resolved] How to fileter taxonomy search and display taxonomy description

This is the technical support forum for Toolset - a suite of plugins for developing WordPress sites without writing PHP.

Everyone can read this forum, but only Toolset clients can post in it. Toolset support works 6 days per week, 19 hours per day.

Sun Mon Tue Wed Thu Fri Sat
- 10:00 – 13:00 10:00 – 13:00 10:00 – 13:00 10:00 – 13:00 10:00 – 13:00 -
- 14:00 – 18:00 14:00 – 18:00 14:00 – 18:00 14:00 – 18:00 14:00 – 18:00 -

Supporter timezone: Asia/Kolkata (GMT+05:30)

This topic contains 0 replies, has 1 voice.

Last updated by Minesh 2 weeks, 6 days ago.

Assisted by: Minesh.

Author
Posts
#2786982

Tell us what you are trying to do?
I need to change the filtering on the teams section. The teams section should load like it is now but to preselect the 'expert-doctors'. Also, on the layout to show the description of each team-top-position description. I tried the following:
[wpv-search-term param="wpv-top-position" format="wpv-top-position-description"]
[wpv-search-term param="wpv-top-position" term="description"]
[wpv-search-term param="wpv-top-position" format="wpv-top-position-description"]
[wpv-search-term param="top-position-description" show="top-position-description"]

Is there any documentation that you are following?
I checked https://toolset.com/documentation/programmer-reference/views/views-shortcodes/#wpv-taxonomy-description

Is there a similar example that we can see?
My current function is:
// filters for all team members by priority category
function filter_include_cat_fn_155( $query_args, $view_settings ) {
if ( isset( $view_settings['view_id'] ) && $view_settings['view_id'] == 155 ) {
if ( empty( $query_args['tax_query'] ) ) {
$query_args['tax_query'][0]['taxonomy'] = 'top-position';
$query_args['tax_query'][0]['field'] = 'slug';
$query_args['tax_query'][0]['terms'] = array( 'expert-doctors', 'embryologists', 'midwives', 'nurses', 'care-taker', 'administration', 'accounting', 'services' );
$query_args['tax_query'][0]['operator'] = 'IN';
$query_args['tax_query'][0]['include_children'] = '';
$query_args['tax_query']['relation'] = 'AND';
}
}
return $query_args;
}
add_filter( 'wpv_filter_query', 'filter_include_cat_fn_155', 1000 , 3 );

What is the link to your site?
isisclinic.com/our-team

#2787078

Minesh
Supporter

Languages: English (English )

Timezone: Asia/Kolkata (GMT+05:30)

Hello. Thank you for contacting the Toolset support.

The shortcode [wpv-search-term] has only one parameter param. You can not modify that.

If you can share problem URL and also tell me with what section you want to display what exactly and where and send me admin access details. You can share all those required information and maybe few screenshots as well. Once I review your requirement I will be able to guide you in the right direction.

*** Please make a FULL BACKUP of your database and website.***
I would also eventually need to request temporary access (WP-Admin and FTP) to your site. Preferably to a test site where the problem has been replicated if possible in order to be of better help and check if some configurations might need to be changed.

I have set the next reply to private which means only you and I have access to it.

#2787098

Minesh
Supporter

Languages: English (English )

Timezone: Asia/Kolkata (GMT+05:30)

Lets go step by step.

To your view:
=> hidden link

I've added the following custom JS code to your view's "Search and Pagination" section's JS editor:
=> hidden link

jQuery(document).ready(function($){
  var params = new window.URLSearchParams(window.location.search);
  var myurl = new URL(window.location.href);
 
  // console.log(myurl.searchParams.has('wpv-team-member-type'));
  if(!myurl.searchParams.has('wpv-top-position')){
    $('#top-position-expert-doctors').attr('checked', true).trigger('change');
  }
   
});

is this the thing you wanted? If yes:

Now, regarding taxonomy description, do you want to display taxonomy term description or taxonomy description. What description you want to display?

When I see the "Expert Doctors" term description, its empty:
=> hidden link