Making WordPress.org


Ignore:
Timestamp:
10/27/2022 04:47:23 PM (3 years ago)
Author:
ryelle
Message:

Pattern Directory: Sync with git WordPress/pattern-directory@fb35733

File:
1 edited

Legend:

Unmodified
Added
Removed
  • sites/trunk/wordpress.org/public_html/wp-content/themes/pub/wporg-patterns/functions.php

    r12085 r12152  
    212212
    213213    return $items->have_posts();
    214 }
    215 
    216 /**
    217  * Get the full, filtered content of a post, ignoring more and noteaser tags and pagination.
    218  *
    219  * See https://github.com/WordPress/wordcamp.org/blob/442ea26d8e6a1b39f97114e933842b1ec4f8eef9/public_html/wp-content/mu-plugins/blocks/includes/content.php#L21
    220  *
    221  * @param int|WP_Post $post Post ID or post object.
    222  * @return string The full, filtered post content.
    223  */
    224 function get_all_the_content( $post ) {
    225     $post = get_post( $post );
    226 
    227     $content = wp_kses_post( $post->post_content );
    228 
    229     /** This filter is documented in wp-includes/post-template.php */
    230     $content = apply_filters( 'the_content', $content );
    231     $content = str_replace( ']]>', ']]>', $content );
    232 
    233     return $content;
    234214}
    235215
Note: See TracChangeset for help on using the changeset viewer.