exclude page/post > Jetack sitemap, which function is correct?
-
Exmple 1
function jeherve_exclude_post_sitemap( $skip, $post ) { if ( '72' == $post->ID ) { $skip = true; } else { $skip = false; } return $skip; } add_filter( 'jetpack_sitemap_skip_post', 'jeherve_exclude_post_sitemap', 10, 2 );
Shea Bunge (@bungeshea) says:
add_filter( 'jetpack_sitemap_skip_post', function ( $skip, $post ) { if ( 72 === $post->ID ) { return true; } return $skip; }, 999, 2 );
Viewing 2 replies - 1 through 2 (of 2 total)
Viewing 2 replies - 1 through 2 (of 2 total)
- The topic ‘exclude page/post > Jetack sitemap, which function is correct?’ is closed to new replies.