*
* @package WordPress
* @subpackage Feed
+ * @since 2.1.0
*/
/**
function get_bloginfo_rss($show = '') {
$info = strip_tags(get_bloginfo($show));
/**
- * Filter the bloginfo for use in RSS feeds.
+ * Filters the bloginfo for use in RSS feeds.
*
* @since 2.2.0
*
*/
function bloginfo_rss($show = '') {
/**
- * Filter the bloginfo for display in RSS feeds.
+ * Filters the bloginfo for display in RSS feeds.
*
* @since 2.1.0
*
* Retrieve the default feed.
*
* The default feed is 'rss2', unless a plugin changes it through the
- * 'default_feed' filter.
+ * {@see 'default_feed'} filter.
*
* @since 2.5.0
*
*/
function get_default_feed() {
/**
- * Filter the default feed type.
+ * Filters the default feed type.
*
* @since 2.5.0
*
}
/**
- * Filter the blog title for use as the feed title.
+ * Filters the blog title for use as the feed title.
*
* @since 2.2.0
* @since 4.4.0 The `$sep` parameter was deprecated and renamed to `$deprecated`.
}
/**
- * Filter the blog title for display of the feed title.
+ * Filters the blog title for display of the feed title.
*
* @since 2.2.0
* @since 4.4.0 The `$sep` parameter was deprecated and renamed to `$deprecated`.
$title = get_the_title();
/**
- * Filter the post title for use in a feed.
+ * Filters the post title for use in a feed.
*
* @since 1.2.0
*
$content = apply_filters( 'the_content', get_the_content() );
$content = str_replace(']]>', ']]>', $content);
/**
- * Filter the post content for use in feeds.
+ * Filters the post content for use in feeds.
*
* @since 2.9.0
*
function the_excerpt_rss() {
$output = get_the_excerpt();
/**
- * Filter the post excerpt for a feed.
+ * Filters the post excerpt for a feed.
*
* @since 1.2.0
*
*/
function the_permalink_rss() {
/**
- * Filter the permalink to the post for use in feeds.
+ * Filters the permalink to the post for use in feeds.
*
* @since 2.3.0
*
*/
function comments_link_feed() {
/**
- * Filter the comments permalink for the current post.
+ * Filters the comments permalink for the current post.
*
* @since 3.6.0
*
*/
function comment_link( $comment = null ) {
/**
- * Filter the current comment's permalink.
+ * Filters the current comment's permalink.
*
* @since 3.6.0
*
*/
function get_comment_author_rss() {
/**
- * Filter the current comment author for use in a feed.
+ * Filters the current comment author for use in a feed.
*
* @since 1.5.0
*
function comment_text_rss() {
$comment_text = get_comment_text();
/**
- * Filter the current comment content for use in a feed.
+ * Filters the current comment content for use in a feed.
*
* @since 1.5.0
*
}
/**
- * Filter all of the post categories for display in a feed.
+ * Filters all of the post categories for display in a feed.
*
* @since 1.2.0
*
$type = $t[0];
/**
- * Filter the RSS enclosure HTML link tag for the current post.
+ * Filters the RSS enclosure HTML link tag for the current post.
*
* @since 2.2.0
*
foreach ( (array) $val as $enc ) {
$enclosure = explode("\n", $enc);
/**
- * Filter the atom enclosure HTML link tag for the current post.
+ * Filters the atom enclosure HTML link tag for the current post.
*
* @since 2.2.0
*
function self_link() {
$host = @parse_url(home_url());
/**
- * Filter the current feed URL.
+ * Filters the current feed URL.
*
* @since 3.6.0
*
* Return the content type for specified feed type.
*
* @since 2.8.0
+ *
+ * @param string $type Type of feed. Possible values include 'rss', rss2', 'atom', and 'rdf'.
*/
function feed_content_type( $type = '' ) {
if ( empty($type) )
$type = get_default_feed();
$types = array(
- 'rss' => 'application/rss+xml',
- 'rss2' => 'application/rss+xml',
- 'rss-http' => 'text/xml',
- 'atom' => 'application/atom+xml',
- 'rdf' => 'application/rdf+xml'
+ 'rss' => 'application/rss+xml',
+ 'rss2' => 'application/rss+xml',
+ 'rss-http' => 'text/xml',
+ 'atom' => 'application/atom+xml',
+ 'rdf' => 'application/rdf+xml'
);
$content_type = ( !empty($types[$type]) ) ? $types[$type] : 'application/octet-stream';
/**
- * Filter the content type for a specific feed type.
+ * Filters the content type for a specific feed type.
*
* @since 2.8.0
*
* @param string $content_type Content type indicating the type of data that a feed contains.
- * @param string $type Type of feed. Possible values include 'rss2', 'atom'.
- * Default 'rss2'.
+ * @param string $type Type of feed. Possible values include 'rss', rss2', 'atom', and 'rdf'.
*/
return apply_filters( 'feed_content_type', $content_type, $type );
}