Last active
September 15, 2020 13:13
-
-
Save mgibbs189/039bac4b0bcce9c980ea980d337040e3 to your computer and use it in GitHub Desktop.
Listable - exclude query for listing archives
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <?php | |
| // Add to your (child) theme's functions.php | |
| add_filter( 'facetwp_is_main_query', function( $is_main_query, $query ) { | |
| if ( $query->is_tax( 'job_listing_category' ) ) { | |
| $is_main_query = false; | |
| } | |
| return $is_main_query; | |
| }, 10, 2 ); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment