SplSubject, Countable
The HTTP client. See http\Client\Curl's options which is the only driver currently supported.
callback's $data# contains human readable text.callback's $data contains data received.callback's $data contains data sent.callback's $data contains headers.callback's $data contains a body part.callback's $data contains SSL data.SplObjectStorage $observers# = NULLarray $options# = NULLNULLbool $recordHistory# = falseCreate a new HTTP client.
void http\Client::__construct([string $driver = NULL[, string $persistent_handle_id = NULL]])
Add custom cookies.
http\Client http\Client::addCookies([array $cookies = NULL])
Add specific SSL options.
http\Client http\Client::addSslOptions([array $ssl_options = NULL])
Implements SplSubject. Attach another observer.
http\Client http\Client::attach(SplObserver $observer)
Configure the client's low level options.
http\Client http\Client::configure(array $configuration)
Implements Countable. Retrieve the number of enqueued requests.
Dequeue the http\Client\Request $request.
http\Client http\Client::dequeue(http\Client\Request $request)
Implements SplSubject. Detach $observer, which has been previously attached.
http\Client http\Client::detach(SplObserver $observer)
Enable usage of an event library like libevent, which might improve performance with big socket sets.
http\Client http\Client::enableEvents([bool $enable = true])
Enable sending pipelined requests to the same host if the driver supports it.
http\Client http\Client::enablePipelining([bool $enable = true])
Add another http\Client\Request to the request queue.
http\Client http\Client::enqueue(http\Client\Request $request[, callable $cb])
Get a list of available configuration options and their default values.
List available drivers.
static array http\Client::getAvailableDrivers()
Retrieve a list of available request options and their default values.
Get priorly set custom cookies.
Simply returns the http\Message chain representing the request/response history.
Returns the SplObjectStorage holding attached observers.
Get priorly set options.
Retrieve the progress information for $request.
object http\Client::getProgressInfo(http\Client\Request $request)
Retrieve the corresponding response of an already finished request, or the last received response if $request is not set.
http\Client\Response http\Client::getResponse([http\Client\Request $request = NULL])
Retrieve priorly set SSL options.
Get transfer related information for a running or finished request.
object http\Client::getTransferInfo(http\Client\Request $request)
Implements SplSubject. Notify attached observers about progress with $request.
http\Client http\Client::notify([http\Client\Request $request = NULL[, object $progress = NULL]])
Perform outstanding transfer actions.
Requeue an http\Client\Request.
http\Client http\Client::requeue(http\Client\Request $request[, callable $cb])
Reset the client to the initial state.
Send all enqueued requests.
Set custom cookies.
http\Client http\Client::setCookies([array $cookies = NULL])
Set client debugging callback.
http\Client http\Client::setDebug(callable $callback)
Set client options.
http\Client http\Client::setOptions([array $options = NULL])
Specifically set SSL options.
http\Client http\Client::setSslOptions([array $ssl_options = NULL])
Wait for $timeout seconds for transfers to provide data.
bool http\Client::wait([float $timeout = 0])
The http\Client\Curl namespace holds option value constants specific to the curl driver of the http\Client.
namespace http\Client\Curl
The http\Client\Request class provides an HTTP message implementation tailored to represent a request message to be sent by the client.
class http\Client\Request extends http\Message
The http\Client\Response class represents an HTTP message the client returns as answer from a server to an http\Client\Request.
class http\Client\Response extends http\Message