Menu Adam R Brown

WP hooks navigation: Home/browseActions indexFilters index

Source View: admin_referrer_policy

To save our bandwidth, we show only a snippet of code around each occurence of the hook. View complete file in SVN (without highlighting).

Understanding Source Code

The best way to understand what a hook does is to look at where it occurs in the source code.

Remember, this hook may occur in more than one file. Moreover, the hook's context may change from version to version.

Source View

Line Code
7157       * Filters the admin referrer policy header value.
7158       *
7159       * @since 4.9.0
7160       * @since 4.9.5 The default value was changed to 'strict-origin-when-cross-origin'.
7161       *
7162       * @link https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Referrer-Policy
7163       *
7164       * @param string $policy The admin referrer policy header value. Default 'strict-origin-when-cross-origin'.
7165       */
7166      $policy = apply_filters( 'admin_referrer_policy', $policy );
7167
7168      header( sprintf( 'Referrer-Policy: %s', $policy ) );
7169 }
7170
7171 /**
7172  * Retrieves a list of protocols to allow in HTML attributes.
7173  *
7174  * @since 3.3.0
7175  * @since 4.3.0 Added 'webcal' to the protocols array.