allowed_http_request_hosts( bool $is_external, string $host ): bool

Mark allowed redirect hosts safe for HTTP requests as well.


Description

Attached to the ‘http_request_host_is_external’ filter.


Top ↑

Parameters

$is_external bool Required
$host string Required

Top ↑

Return

bool


Top ↑

Source

File: wp-includes/http.php. View all references

function allowed_http_request_hosts( $is_external, $host ) {
	if ( ! $is_external && wp_validate_redirect( 'http://' . $host ) ) {
		$is_external = true;
	}
	return $is_external;
}


Top ↑

Changelog

Changelog
Version Description
3.6.0 Introduced.

Top ↑

User Contributed Notes

You must log in before being able to contribute a note or feedback.