is_sticky filter-hook . WP 5.3.0
Filters whether a post is sticky.
Usage
add_filter( 'is_sticky', 'filter_function_name_8672', 10, 2 ); function filter_function_name_8672( $is_sticky, $post_id ){ // filter... return $is_sticky; }
- $is_sticky(true/false)
- Whether a post is sticky.
- $post_id(int)
- Post ID.
Changelog
Since 5.3.0 | Introduced. |
Where the hook is called
is_sticky
wp-includes/post.php 2322
return apply_filters( 'is_sticky', $is_sticky, $post_id );