allowed_http_request_hosts()
Marks allowed redirect hosts safe for HTTP requests as well.
Attached to the http_request_host_is_external filter.
Хуков нет.
Возвращает
bool.
Использование
allowed_http_request_hosts( $is_external, $host );
- $is_external(true|false) (обязательный)
- .
- $host(строка) (обязательный)
- .
Список изменений
| С версии 3.6.0 | Введена. |
Код allowed_http_request_hosts() allowed http request hosts WP 7.1.3
function allowed_http_request_hosts( $is_external, $host ) {
if ( ! $is_external && wp_validate_redirect( 'http://' . $host ) ) {
$is_external = true;
}
return $is_external;
}