the_excerpt_rss

Sponsored Link

RSSにフォーマットされた現在の投稿の抜粋が表示されます。あなたが投稿(投稿エディタのオプションの抜粋フィールド)に明確な抜粋を提供しない場合は、投稿のコンテンツの最初の55の単語が使用されます。このタグは、The_Loop以内にする必要があります。

Sponsored Link

Displays the excerpt of the current post formatted for RSS.If you do not provide an explicit excerpt to a post (in the post editor’s optional excerpt field), the first 55 words of the post’s content are used. This tag must be within The_Loop.

the_excerpt_rssのテンプレートタグ使用方法

<?php the_excerpt_rss(); ?> 

the_excerpt_rssのパラメーター

このタグはパラメーターがありません。

This tag has no parameters.

注:v1.2の引数は、そのバージョンで使用できるパラメーターを参照してください。

Note: See Parameters for v1.2 for arguments available in that version.

記事の抜粋や、RSSシンジケーションでフォーマットされた抜粋のない投稿内容の最初の120語を表示します。

Displays the post’s excerpt, or the first 120 words of the post’s content when no excerpt exists, formatted for RSS syndication.

<description><?php the_excerpt_rss(); ?></description> 

Version 1.2

WordPressのバージョン1.5では、このタグのパラメーターをサポートしていません。次の情報は1.2ユーザーの利益のために保持されます。

WordPress version 1.5 does not support parameters for this tag. The following information is retained for the benefit of 1.2 users.

v1.2のテンプレートタグ使用方法

<?php the_excerpt_rss( $cut, $encode_html ); ?> 

v1.2のパラメーター

$cut

(integer)抜粋を終了する前に表示される単語数です。デフォルトで任意の数値が最大にすることができます。

(integer) Number of words to display before ending the excerpt. Can be any numeric value up to the default.

$encode_html

(integer) HTMLタグフィルタリングして特殊文字(例:’&’)のエンコーディングして定義します。オプションがあります:

(integer) Defines html tag filtering and special character (e.g. ‘&’) encoding. Options are:

  • 0 窶・(デフォルト)”URLの脚注”の番号に外部リンクを解析します 。
  • 1 窶・PHP関数のhtmlspecialchars()を通じてフィルタだけでなく、0にカットしてセットされるので、カットパラメーターを使用する時は推奨されません。
  • 2 窶・Strips HTMLタグは、HTMLエンティティと同等の’&’に置き換えられます(&)。これはカットパラメーターを使用している時のデフォルトです。
  • 0 – (Default) Parses out links for numbered “url footnotes”.
  • 1 – Filters through the PHP function htmlspecialchars(), but also sets cut to 0, so is not recommended when using the cut parameter.
  • 2 – Strips html tags, and replaces ‘&’ with HTML entity equivalent (&). This is the default when using the cut parameter.

関連テンプレートタグ

the_ID, the_title, the_title_attribute, single_post_title, the_title_rss, the_content, the_content_rss, the_excerpt, the_excerpt_rss, wp_link_pages, next_post_link, next_posts_link, previous_post_link, previous_posts_link, posts_nav_link, sticky_class, the_meta

Sponsored Link