[ Index ]

PHP Cross Reference of WordPress Trunk (Updated Daily)

Search

title

Body

[close]

/wp-content/themes/twentytwentyone/template-parts/excerpt/ -> excerpt-chat.php (source)

   1  <?php
   2  /**
   3   * Show the appropriate content for the Chat post format.
   4   *
   5   * @link https://developer.wordpress.org/themes/basics/template-hierarchy/
   6   *
   7   * @package WordPress
   8   * @subpackage Twenty_Twenty_One
   9   * @since Twenty Twenty-One 1.0
  10   */
  11  
  12  // If there are paragraph blocks, print up to two.
  13  // Otherwise this is legacy content, so print the excerpt.
  14  if ( has_block( 'core/paragraph', get_the_content() ) ) {
  15  
  16      twenty_twenty_one_print_first_instance_of_block( 'core/paragraph', get_the_content(), 2 );
  17  } else {
  18  
  19      the_excerpt();
  20  }


Generated : Thu Nov 21 08:20:01 2024 Cross-referenced by PHPXref