WordPress.org

Make WordPress Core

Changeset 5907


Ignore:
Timestamp:
08/20/2007 10:55:43 PM (14 years ago)
Author:
ryan
Message:

wp_reset_query() from mdawaffe. fixes #4741

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/wp-includes/query.php

    r5873 r5907  
    2121    $GLOBALS['wp_query'] =& new WP_Query();
    2222    return $GLOBALS['wp_query']->query($query);
     23}
     24
     25function wp_reset_query() {
     26    unset($GLOBALS['wp_query']);
     27    $GLOBALS['wp_query'] =& $GLOBALS['wp_the_query'];
    2328}
    2429
Note: See TracChangeset for help on using the changeset viewer.