Skip to content

Instantly share code, notes, and snippets.

@tripflex
Created February 28, 2021 20:35
Show Gist options
  • Save tripflex/b2cbf8b2c7a35d7736e048865276b2b3 to your computer and use it in GitHub Desktop.
Save tripflex/b2cbf8b2c7a35d7736e048865276b2b3 to your computer and use it in GitHub Desktop.
Remove Taxonomy Ordering when using WP Job Manager Search and Filtering (native ordering)
<?php
add_filter( 'search_and_filtering_get_taxonomy_data_options_args', 'smyles_sf_remove_tax_ordering' );
function smyles_sf_remove_tax_ordering( $args ){
if( isset( $args['order'] ) ){
unset( $args['order'] );
}
if ( isset( $args['orderby'] ) ) {
unset( $args['orderby'] );
}
return $args;
}
@tripflex
Copy link
Author

tripflex commented Mar 2, 2021

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment