web/wp-includes/feed-atom-comments.php
changeset 204 09a1c134465b
parent 194 32102edaa81b
equal deleted inserted replaced
203:f507feede89a 204:09a1c134465b
    14 	xmlns:thr="http://purl.org/syndication/thread/1.0"
    14 	xmlns:thr="http://purl.org/syndication/thread/1.0"
    15 	<?php do_action('atom_ns'); do_action('atom_comments_ns'); ?>
    15 	<?php do_action('atom_ns'); do_action('atom_comments_ns'); ?>
    16 >
    16 >
    17 	<title type="text"><?php
    17 	<title type="text"><?php
    18 		if ( is_singular() )
    18 		if ( is_singular() )
    19 			printf(ent2ncr(__('Comments on %s')), get_the_title_rss());
    19 			printf( ent2ncr( __( 'Comments on %s' ) ), get_the_title_rss() );
    20 		elseif ( is_search() )
    20 		elseif ( is_search() )
    21 			printf(ent2ncr(__('Comments for %1$s searching on %2$s')), get_bloginfo_rss( 'name' ), get_search_query() );
    21 			printf( ent2ncr( __( 'Comments for %1$s searching on %2$s' ) ), get_bloginfo_rss( 'name' ), get_search_query() );
    22 		else
    22 		else
    23 			printf(ent2ncr(__('Comments for %s')), get_bloginfo_rss( 'name' ) . get_wp_title_rss());
    23 			printf( ent2ncr( __( 'Comments for %s' ) ), get_bloginfo_rss( 'name' ) . get_wp_title_rss() );
    24 	?></title>
    24 	?></title>
    25 	<subtitle type="text"><?php bloginfo_rss('description'); ?></subtitle>
    25 	<subtitle type="text"><?php bloginfo_rss('description'); ?></subtitle>
    26 
    26 
    27 	<updated><?php echo mysql2date('Y-m-d\TH:i:s\Z', get_lastcommentmodified('GMT'), false); ?></updated>
    27 	<updated><?php echo mysql2date('Y-m-d\TH:i:s\Z', get_lastcommentmodified('GMT'), false); ?></updated>
    28 
    28 
    29 <?php if ( is_singular() ) { ?>
    29 <?php if ( is_singular() ) { ?>
    30 	<link rel="alternate" type="<?php bloginfo_rss('html_type'); ?>" href="<?php comments_link_feed(); ?>" />
    30 	<link rel="alternate" type="<?php bloginfo_rss('html_type'); ?>" href="<?php comments_link_feed(); ?>" />
    31 	<link rel="self" type="application/atom+xml" href="<?php echo get_post_comments_feed_link('', 'atom'); ?>" />
    31 	<link rel="self" type="application/atom+xml" href="<?php echo esc_url( get_post_comments_feed_link('', 'atom') ); ?>" />
    32 	<id><?php echo get_post_comments_feed_link('', 'atom'); ?></id>
    32 	<id><?php echo esc_url( get_post_comments_feed_link('', 'atom') ); ?></id>
    33 <?php } elseif(is_search()) { ?>
    33 <?php } elseif(is_search()) { ?>
    34 	<link rel="alternate" type="<?php bloginfo_rss('html_type'); ?>" href="<?php echo home_url() . '?s=' . get_search_query(); ?>" />
    34 	<link rel="alternate" type="<?php bloginfo_rss('html_type'); ?>" href="<?php echo home_url() . '?s=' . get_search_query(); ?>" />
    35 	<link rel="self" type="application/atom+xml" href="<?php echo get_search_comments_feed_link('', 'atom'); ?>" />
    35 	<link rel="self" type="application/atom+xml" href="<?php echo get_search_comments_feed_link('', 'atom'); ?>" />
    36 	<id><?php echo get_search_comments_feed_link('', 'atom'); ?></id>
    36 	<id><?php echo get_search_comments_feed_link('', 'atom'); ?></id>
    37 <?php } else { ?>
    37 <?php } else { ?>