Codex

Template Tags/the content rss

Contents

Description

Displays the content of the current post formatted for RSS. This tag must be within The_Loop.

This tag will display a "teaser" link to read more of a post, when on non-single/non-permalink post pages and the <!--more--> Quicktag is used.

Usage

 <?php the_content_rss('more_link_text'strip_teaser,
                      
'more_file'cutencode_html); ?> 

Examples

Default Usage

Displays the content in RSS format using defaults.

 <?php the_content_rss(); ?>

Hides Teaser Link and Limits Content

Displays the content in RSS format, hides the teaser link and cuts the content after 50 words.

 <?php the_content_rss('', TRUE, '', 50); ?>

Parameters

more_link_text 
(string) Link text to display for the "more" link. Defaults to '(more...)'.
strip_teaser 
(boolean) Should the text before the "more" link be hidden (TRUE) or displayed (FALSE). Defaults to FALSE.
more_file 
(string) File which the "more" link points to. Defaults to the current file.
cut 
(integer) Number of words displayed before ending content. Default is 0 (display all).
encode_html 
(integer) Defines html tag filtering and special character (e.g. '&') encoding. Options are:
  • 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 (&amp;). This is the default when using the cut parameter.

Related

the_ID, the_title, the_title_attribute, single_post_title, the_title_rss, the_content, the_content_rss, the_excerpt, the_excerpt_rss, previous_post_link, next_post_link, posts_nav_link, the_meta,

How to pass parameters to tags with PHP function-style parameters

Go to Template Tag index