WordPress.org

Make WordPress Core

Changeset 25702


Ignore:
Timestamp:
10/06/2013 06:40:29 PM (6 years ago)
Author:
DrewAPicture
Message:

Inline documentation for hooks in wp-includes/template-loader.php.

Props jonlynch.
Fixes #25488.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/wp-includes/template-loader.php

    r25292 r25702  
    55 */
    66if ( defined('WP_USE_THEMES') && WP_USE_THEMES )
    7     do_action('template_redirect');
     7    /**
     8     * Fires before determining which template to load.
     9     *
     10     * @since 1.5.2
     11     */
     12    do_action( 'template_redirect' );
    813
    9 // Halt template load for HEAD requests. Performance bump. See #14348
     14/**
     15 * Filter whether to allow 'HEAD' requests to generate content.
     16 *
     17 * Provides a significant performance bump by exiting before the page
     18 * content loads for 'HEAD' requests. See #14348.
     19 *
     20 * @since 3.5.0
     21 *
     22 * @param bool $exit Whether to exit without generating any content for 'HEAD' requests. Default true.
     23 */
    1024if ( 'HEAD' === $_SERVER['REQUEST_METHOD'] && apply_filters( 'exit_on_http_head', true ) )
    1125    exit();
     
    1327// Process feeds and trackbacks even if not using themes.
    1428if ( is_robots() ) :
    15     do_action('do_robots');
     29    /**
     30     * Fired when the template loader determines a robots.txt request.
     31     *
     32     * @since 2.1.0
     33     */
     34    do_action( 'do_robots' );
    1635    return;
    1736elseif ( is_feed() ) :
     
    4564        $template = get_index_template();
    4665    endif;
     66    /**
     67     * Filter the path of the current template before including it.
     68     *
     69     * @since 3.0.0
     70     *
     71     * @param string $template The path of the template to include.
     72     */
    4773    if ( $template = apply_filters( 'template_include', $template ) )
    4874        include( $template );
Note: See TracChangeset for help on using the changeset viewer.