Changeset 11406
- Timestamp:
- 05/20/2009 04:05:23 PM (15 years ago)
- Location:
- trunk/wp-includes
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/wp-includes/classes.php
r11380 r11406 415 415 } 416 416 417 $GLOBALS['query_string'] = &$this->query_string;417 $GLOBALS['query_string'] = $this->query_string; 418 418 $GLOBALS['posts'] = & $wp_query->posts; 419 $GLOBALS['post'] = &$wp_query->post;420 $GLOBALS['request'] = &$wp_query->request;419 $GLOBALS['post'] = $wp_query->post; 420 $GLOBALS['request'] = $wp_query->request; 421 421 422 422 if ( is_single() || is_page() ) { -
trunk/wp-includes/query.php
r11400 r11406 74 74 */ 75 75 function wp_reset_query() { 76 foreach ( array('id', 'authordata', 'day', 'currentmonth', 'page', 'pages', 'multipage', 'more', 'numpages', 'post', 'wp_query') as $var ) 77 unset($GLOBALS[$var]); 76 unset($GLOBALS['wp_query']); 78 77 $GLOBALS['wp_query'] =& $GLOBALS['wp_the_query']; 79 78 global $wp_query; … … 2376 2375 */ 2377 2376 function the_post() { 2378 unset($GLOBALS['post']); // Break the ref2379 2377 global $post; 2380 2378 $this->in_the_loop = true; 2381 2379 $post = $this->next_post(); 2382 2380 setup_postdata($post); 2383 do_action('the_post', $post);2384 2381 2385 2382 if ( $this->current_post == 0 ) // loop has just started … … 2650 2647 * 2651 2648 * @param object $post Post data. 2649 * @uses do_action_ref_array() Calls 'the_post' 2652 2650 * @return bool True when finished. 2653 2651 */ … … 2655 2653 global $id, $authordata, $day, $currentmonth, $page, $pages, $multipage, $more, $numpages; 2656 2654 2655 do_action_ref_array('the_post', array(&$post)); 2656 2657 2657 $id = (int) $post->ID; 2658 2658
Note: See TracChangeset
for help on using the changeset viewer.