Move send_nosniff_header() into wp-includes so it can be used in wp-ajax.php. props sivel, fixes #12683
git-svn-id: https://develop.svn.wordpress.org/trunk@13806 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
parent
e5f55c5b3d
commit
5bcb23827d
@ -654,22 +654,10 @@ function win_is_writable($path) {
|
|||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
|
||||||
* Send a HTTP header to disable content type sniffing in browsers which support it.
|
|
||||||
*
|
|
||||||
* @link http://blogs.msdn.com/ie/archive/2008/07/02/ie8-security-part-v-comprehensive-protection.aspx
|
|
||||||
* @link http://src.chromium.org/viewvc/chrome?view=rev&revision=6985
|
|
||||||
*
|
|
||||||
* @since 3.0.0.
|
|
||||||
* @return none
|
|
||||||
*/
|
|
||||||
function send_nosniff_header() {
|
|
||||||
@header( 'X-Content-Type-Options: nosniff' );
|
|
||||||
}
|
|
||||||
/**
|
/**
|
||||||
* Display the default admin color scheme picker (Used in user-edit.php)
|
* Display the default admin color scheme picker (Used in user-edit.php)
|
||||||
*
|
*
|
||||||
* @since 3.0
|
* @since 3.0.0
|
||||||
*/
|
*/
|
||||||
function admin_color_scheme_picker() {
|
function admin_color_scheme_picker() {
|
||||||
global $_wp_admin_css_colors, $user_id; ?>
|
global $_wp_admin_css_colors, $user_id; ?>
|
||||||
|
@ -4082,3 +4082,18 @@ function __return_true() {
|
|||||||
function __return_false() {
|
function __return_false() {
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Send a HTTP header to disable content type sniffing in browsers which support it.
|
||||||
|
*
|
||||||
|
* @link http://blogs.msdn.com/ie/archive/2008/07/02/ie8-security-part-v-comprehensive-protection.aspx
|
||||||
|
* @link http://src.chromium.org/viewvc/chrome?view=rev&revision=6985
|
||||||
|
*
|
||||||
|
* @since 3.0.0
|
||||||
|
* @return none
|
||||||
|
*/
|
||||||
|
function send_nosniff_header() {
|
||||||
|
@header( 'X-Content-Type-Options: nosniff' );
|
||||||
|
}
|
||||||
|
|
||||||
|
?>
|
Loading…
Reference in New Issue
Block a user