acf/shortcode/post_not_public_message
acf/shortcode/post_not_public_message
Appears in: advanced-custom-fields.6.3.5
Hook Type: filter
Displaying hooks found in version: advanced-custom-fields.6.3.5apply_filters('acf/shortcode/post_not_public_message') is found 1 times:
- /includes/api/api-template.php line 1054
// If we've decoded to a post, ensure the post is publicly visible. if ( $decoded_post_id['type'] === 'post' ) { if ( $atts['post_id'] !== false && ( (int) $atts['post_id'] !== (int) acf_get_valid_post_id() ) && ( ! is_post_publicly_viewable( $decoded_post_id['id'] ) ) && apply_filters( 'acf/shortcode/prevent_access_to_fields_on_non_public_posts', true ) ) { if ( is_preview() ) { return apply_filters( 'acf/shortcode/post_not_public_message', __( '[The ACF shortcode cannot display fields from non-public posts]', 'acf' ) ); } else { return; } } }