WordPress开发者和主题制作者的搜索引擎



the_content ›

Since0.71
已弃用n/a
the_content ( $more_link_text = null, $strip_teaser = false )
参数: (2)
  • (string) $more_link_text Optional. Content for when there is more text.
    Required: No
    默认: null
  • (bool) $strip_teaser Optional. Strip teaser content before the more text. Default is false.
    Required: No
    默认: false
定义在:
文档:

Display the post content.



源码

function the_content( $more_link_text = null, $strip_teaser = false ) {
	$content = get_the_content( $more_link_text, $strip_teaser );

	/**
	 * Filters the post content.
	 *
	 * @since 0.71
	 *
	 * @param string $content Content of the current post.
	 */
	$content = apply_filters( 'the_content', $content );
	$content = str_replace( ']]>', ']]>', $content );
	echo $content;
}