the_excerpt

函数
the_excerpt ( No parameters )

the_excerpt – 这个函数用来输出一个文章或页面的内容的缩短版。摘录的长度是由WordPress设置中的摘录长度决定的。

显示文章的摘要。

Plain text
Copy to clipboard
Open code in new window
EnlighterJS 3 Syntax Highlighter
function the_excerpt() {
/**
* Filters the displayed post excerpt.
*
* @since 0.71
*
* @see get_the_excerpt()
*
* @param string $post_excerpt The post excerpt.
*/
echo apply_filters( 'the_excerpt', get_the_excerpt() );
}
function the_excerpt() { /** * Filters the displayed post excerpt. * * @since 0.71 * * @see get_the_excerpt() * * @param string $post_excerpt The post excerpt. */ echo apply_filters( 'the_excerpt', get_the_excerpt() ); }
function the_excerpt() {

	/**
	 * Filters the displayed post excerpt.
	 *
	 * @since 0.71
	 *
	 * @see get_the_excerpt()
	 *
	 * @param string $post_excerpt The post excerpt.
	 */
	echo apply_filters( 'the_excerpt', get_the_excerpt() );
}

常见问题

FAQs
查看更多 >