ONLY send subscription emails for these categories Will ONLY send subscription emails to these categories.
Parameters
- $args
array Array of category slugs or ID's.
Changelog
- Introduced in Jetpack 3.7.0
How to use this hook
Notes
If you’d rather not send any subscription emails by default, you can use thejetpack_subscriptions_exclude_all_categories_except filter.
In the example below, we only send subscription emails if our post belongs to the “VaultPress” or “Akismet” category:
function jetpackme_exclude_all_posts_subscriptions_except( $categories ) {
$categories = array( 'vaultpress', 'akismet');
return $categories;
}
add_filter( 'jetpack_subscriptions_exclude_all_categories_except', 'jetpackme_exclude_all_posts_subscriptions_except' );