diff --git a/wp-blog-header.php b/wp-blog-header.php index 19146199d7..df9335c9ee 100644 --- a/wp-blog-header.php +++ b/wp-blog-header.php @@ -89,8 +89,10 @@ if (!isset($doing_rss) || !$doing_rss) { @header ('X-Pingback: ' . get_settings('siteurl') . '/xmlrpc.php'); // Support for Conditional GET - $client_last_modified = $_SERVER['HTTP_IF_MODIFIED_SINCE']; - $client_etag = stripslashes($_SERVER['HTTP_IF_NONE_MATCH']); + if (isset($_SERVER['HTTP_IF_MODIFIED_SINCE'])) $client_last_modified = $_SERVER['HTTP_IF_MODIFIED_SINCE']; + else $client_last_modified = false; + if (isset($_SERVER['HTTP_IF_NONE_MATCH'])) $client_etag = stripslashes($_SERVER['HTTP_IF_NONE_MATCH']); + else $client_etag = false; if ( ($client_last_modified && $client_etag) ? (($client_last_modified == $wp_last_modified) && ($client_etag == $wp_etag)) : diff --git a/wp-includes/template-functions-comment.php b/wp-includes/template-functions-comment.php index 00b5f6ee87..e7fd17e9c8 100644 --- a/wp-includes/template-functions-comment.php +++ b/wp-includes/template-functions-comment.php @@ -216,16 +216,20 @@ function comment_time($d='') { } function comments_rss_link($link_text='Comments RSS', $commentsrssfilename = 'wp-commentsrss2.php') { + $url = comments_rss($commentsrssfilename); + echo "$link_text"; +} + +function comments_rss($commentsrssfilename = 'wp-commentsrss2.php') { global $id; global $querystring_start, $querystring_equal, $querystring_separator; if ('' != get_settings('permalink_structure')) { - $url = trailingslashit(get_permalink()) . 'rss2/'; + $url = trailingslashit(get_permalink()) . 'feed/'; } else { $url = get_settings('siteurl') . '/' . $commentsrssfilename.$querystring_start.'p'.$querystring_equal.$id; } - - echo "$link_text"; + return $url; } function comment_author_rss() { diff --git a/wp-rss2.php b/wp-rss2.php index bab2aae428..83714914f2 100644 --- a/wp-rss2.php +++ b/wp-rss2.php @@ -14,7 +14,9 @@ header('Content-type: text/xml', true); + xmlns:content="http://purl.org/rss/1.0/modules/content/" + xmlns:wfw="http://wellformedweb.org/CommentAPI/" +> <?php bloginfo_rss('name') ?> @@ -38,7 +40,7 @@ header('Content-type: text/xml', true); ]]> - +