Skip to content

Instantly share code, notes, and snippets.

@jchristopher
Created April 22, 2019 13:09
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save jchristopher/0e011ac1c486995142d87df165fdc9c1 to your computer and use it in GitHub Desktop.
Save jchristopher/0e011ac1c486995142d87df165fdc9c1 to your computer and use it in GitHub Desktop.
Modify taxonomy terms for posts during SearchWP indexing.
<?php
// Modify taxonomy terms for posts during SearchWP indexing.
add_filter( 'searchwp_indexer_taxonomy_terms', function( $terms, $taxonomy, $post_being_indexed ) {
// TODO: modify $terms in any way you'd like.
return $terms;
}, 20, 3 );
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment