WpOrg\Requests
Requests::get_transport()
Get a working transport.
Method of the class: Requests{}
No Hooks.
Return
\WpOrg\Requests\Transport
.
Usage
$result = Requests::get_transport( $capabilities );
- $capabilities(array)
- -
Default: []
Requests::get_transport() Requests::get transport code WP 6.6.2
protected static function get_transport(array $capabilities = []) { $class = self::get_transport_class($capabilities); if ($class === '') { throw new Exception('No working transports found', 'notransport', self::$transports); } return new $class(); }