WordPress Development Stack Exchange is a question and answer site for WordPress developers and administrators. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

It is referenced in load_template but Wp does nothing with it ?!!! so what's the use ?

1105  function load_template( $_template_file, $require_once = true ) {
1106      global $posts, $post, $wp_did_header, $wp_did_template_redirect, $wp_query, $wp_rewrite, $wpdb, $wp_version, $wp, $id, $comment, $user_ID;
1108      if ( is_array( $wp_query->query_vars ) )
1109          extract( $wp_query->query_vars, EXTR_SKIP );
1111      if ( $require_once )
1112          require_once( $_template_file );
1113      else
1114          require( $_template_file );
1115  }
share|improve this question
up vote 5 down vote accepted

It's a global variable that can be checked by user functions and filters to see whether or not WordPress has already sent headers. It's just there to help.

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.