Ticket #11028: get_the_content-dead_code.11028.diff
| File get_the_content-dead_code.11028.diff, 2.6 KB (added by , 17 years ago) |
|---|
-
wp-includes/post-template.php
160 160 * 161 161 * @param string $more_link_text Optional. Content for when there is more text. 162 162 * @param string $stripteaser Optional. Teaser content before the more text. 163 * @param string $more_file Optional. Not used.164 163 */ 165 function the_content($more_link_text = null, $stripteaser = 0 , $more_file = '') {166 $content = get_the_content($more_link_text, $stripteaser , $more_file);164 function the_content($more_link_text = null, $stripteaser = 0) { 165 $content = get_the_content($more_link_text, $stripteaser); 167 166 $content = apply_filters('the_content', $content); 168 167 $content = str_replace(']]>', ']]>', $content); 169 168 echo $content; … … 176 175 * 177 176 * @param string $more_link_text Optional. Content for when there is more text. 178 177 * @param string $stripteaser Optional. Teaser content before the more text. 179 * @param string $more_file Optional. Not used.180 178 * @return string 181 179 */ 182 function get_the_content($more_link_text = null, $stripteaser = 0 , $more_file = '') {180 function get_the_content($more_link_text = null, $stripteaser = 0) { 183 181 global $id, $post, $more, $page, $pages, $multipage, $preview, $pagenow; 184 182 185 183 if ( null === $more_link_text ) … … 194 192 return $output; 195 193 } 196 194 197 if ( $more_file != '' )198 $file = $more_file;199 else200 $file = $pagenow; //$_SERVER['PHP_SELF'];201 202 195 if ( $page > count($pages) ) // if the requested page doesn't exist 203 196 $page = count($pages); // give them the highest numbered page that DOES exist 204 197 … … 549 542 * each bookmarks. 550 543 * 'after' - Default is '</p>' (string). The html or text to append to each 551 544 * bookmarks. 552 * 'more_file' - Default is '' (string) Page the links should point to. Defaults553 * to the current page.554 545 * 'link_before' - Default is '' (string). The html or text to prepend to each 555 546 * Pages link inside the <a> tag. 556 547 * 'link_after' - Default is '' (string). The html or text to append to each … … 568 559 'link_before' => '', 'link_after' => '', 569 560 'next_or_number' => 'number', 'nextpagelink' => __('Next page'), 570 561 'previouspagelink' => __('Previous page'), 'pagelink' => '%', 571 ' more_file' => '', 'echo' => 1562 'echo' => 1 572 563 ); 573 564 574 565 $r = wp_parse_args( $args, $defaults ); 575 566 extract( $r, EXTR_SKIP ); 576 567 577 568 global $post, $page, $numpages, $multipage, $more, $pagenow; 578 if ( $more_file != '' )579 $file = $more_file;580 else581 $file = $pagenow;582 569 583 570 $output = ''; 584 571 if ( $multipage ) {