Ticket #137: 137.diff
| File 137.diff, 2.6 KB (added by mdawaffe, 7 years ago) |
|---|
-
wp-includes/classes.php
1 1 <?php 2 2 3 3 class WP { 4 var $public_query_vars = array('m', 'p', 'posts', 'w', 'cat', 'withcomments', ' s', 'search', 'exact', 'sentence', 'debug', 'calendar', 'page', 'paged', 'more', 'tb', 'pb', 'author', 'order', 'orderby', 'year', 'monthnum', 'day', 'hour', 'minute', 'second', 'name', 'category_name', 'feed', 'author_name', 'static', 'pagename', 'page_id', 'error', 'comments_popup', 'attachment', 'attachment_id', 'subpost', 'subpost_id', 'preview', 'robots');4 var $public_query_vars = array('m', 'p', 'posts', 'w', 'cat', 'withcomments', 'withoutcomments', 's', 'search', 'exact', 'sentence', 'debug', 'calendar', 'page', 'paged', 'more', 'tb', 'pb', 'author', 'order', 'orderby', 'year', 'monthnum', 'day', 'hour', 'minute', 'second', 'name', 'category_name', 'feed', 'author_name', 'static', 'pagename', 'page_id', 'error', 'comments_popup', 'attachment', 'attachment_id', 'subpost', 'subpost_id', 'preview', 'robots'); 5 5 6 6 var $private_query_vars = array('offset', 'posts_per_page', 'posts_per_archive_page', 'what_to_show', 'showposts', 'nopaging', 'post_type'); 7 7 var $extra_query_vars = array(); … … 178 178 @header('Content-type: ' . get_option('html_type') . '; charset=' . get_option('blog_charset')); 179 179 } else { 180 180 // We're showing a feed, so WP is indeed the only thing that last changed 181 if ( $this->query_vars['withcomments'] ) 181 if ( $this->query_vars['withcomments'] 182 || ( !$this->query_vars['withoutcomments'] 183 && ( $this->query_vars['p'] 184 || $this->query_vars['name'] 185 || $this->query_vars['page_id'] 186 || $this->query_vars['pagename'] 187 || $this->query_vars['attachment'] 188 || $this->query_vars['attachment_id'] 189 ) 190 ) 191 ) 182 192 $wp_last_modified = mysql2date('D, d M Y H:i:s', get_lastcommentmodified('GMT'), 0).' GMT'; 183 193 else 184 194 $wp_last_modified = mysql2date('D, d M Y H:i:s', get_lastpostmodified('GMT'), 0).' GMT'; -
wp-includes/functions.php
815 815 $feed = 'rss2'; 816 816 817 817 $for_comments = false; 818 if ( is_singular() || get_query_var('withcomments') == 1 || $feed == 'comments-rss2') {818 if ( 1 != get_query_var('withoutcomments') && ( is_singular() || get_query_var('withcomments') == 1 || $feed == 'comments-rss2' ) ) { 819 819 $feed = 'rss2'; 820 820 $for_comments = true; 821 821 }
