diff --git src/wp-includes/template.php src/wp-includes/template.php
index afc2ca6edf..f42f3f91c0 100644
|
|
function locate_template( $template_names, $load = false, $load_once = true, $ar |
733 | 733 | * @since 1.5.0 |
734 | 734 | * @since 5.5.0 The `$args` parameter was added. |
735 | 735 | * |
736 | | * @global array $posts |
737 | | * @global WP_Post $post Global post object. |
738 | | * @global bool $wp_did_header |
739 | 736 | * @global WP_Query $wp_query WordPress Query object. |
740 | | * @global WP_Rewrite $wp_rewrite WordPress rewrite component. |
741 | | * @global wpdb $wpdb WordPress database abstraction object. |
742 | | * @global string $wp_version |
743 | | * @global WP $wp Current WordPress environment instance. |
744 | | * @global int $id |
745 | | * @global WP_Comment $comment Global comment object. |
746 | | * @global int $user_ID |
747 | 737 | * |
748 | 738 | * @param string $_template_file Path to template file. |
749 | 739 | * @param bool $load_once Whether to require_once or require. Default true. |
… |
… |
function locate_template( $template_names, $load = false, $load_once = true, $ar |
751 | 741 | * Default empty array. |
752 | 742 | */ |
753 | 743 | function load_template( $_template_file, $load_once = true, $args = array() ) { |
754 | | global $posts, $post, $wp_did_header, $wp_query, $wp_rewrite, $wpdb, $wp_version, $wp, $id, $comment, $user_ID; |
| 744 | global $wp_query; |
755 | 745 | |
756 | 746 | if ( is_array( $wp_query->query_vars ) ) { |
757 | 747 | /* |