Skip to content

Instantly share code, notes, and snippets.

@jchristopher
Last active August 29, 2015 14:19
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/bd0053d4cf56962755ba to your computer and use it in GitHub Desktop.
Save jchristopher/bd0053d4cf56962755ba to your computer and use it in GitHub Desktop.
Add our WooCommerce Variation SKU meta key to the SearchWP settings
<?php
// reference: https://gist.github.com/jchristopher/0cad8418fd9477c57b53
function my_searchwp_custom_field_keys_variation_skus( $keys ) {
$keys[] = 'my_product_variation_skus';
return $keys;
}
add_filter( 'searchwp_custom_field_keys', 'my_searchwp_custom_field_keys_variation_skus', 10, 1 );
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment