WpOrg\Requests
Requests::has_capabilities()
Checks to see if we have a transport for the capabilities requested.
Supported capabilities can be found in the Capability{} interface as constants.
Example usage: Requests::has_capabilities([Capability::SSL => true]).
Метод класса: Requests{}
Хуков нет.
Возвращает
true|false
. Whether the transport has the requested capabilities.
Использование
$result = Requests::has_capabilities( $capabilities );
- $capabilities(массив)
- -
По умолчанию: []
Код Requests::has_capabilities() Requests::has capabilities WP 6.6.1
public static function has_capabilities(array $capabilities = []) { return self::get_transport_class($capabilities) !== ''; }