- class
URLConnection
(php\net\URLConnection
) - package
std
- source
php/net/URLConnection.php
Description
Class URLConnection
->
doOutput
:bool
->
doInput
:bool
->
requestMethod
:string
- POST, GET, PUT, etc.->
connectTimeout
:int millis
- that specifies the connect timeout value in milliseconds->
readTimeout
:int millis
- the read timeout to a specified timeout, in milliseconds.->
useCaches
:bool
->
ifModifiedSince
:int millis
->
followRedirects
:bool
->
url
:URL
->
responseCode
:int
->
responseMessage
:int
->
contentLength
:int bytes
- int the content length of the resource that this connection's URL references, -1 if the content length is not known, or if the content length is greater than Integer.MAX_VALUE.->
contentType
:string
->
contentEncoding
:string
->
expiration
:int
->
lastModified
:int
->
usingProxy
:bool
URLConnection ::
guessContentTypeFromStream()
- Tries to determine the type of an input stream based on theURLConnection ::
guessContentTypeFromName()
URLConnection ::
create()
URLConnection ::
enableSSLVerificationForHttps()
- Enable checking ssl for httpsURLConnection ::
disableSSLVerificationForHttps()
- Disable checking ssl for https
->
__construct()
->
connect()
- Opens a communications link to the resource referenced by this->
getHeaderField()
->
getHeaderFields()
->
getInputStream()
->
getErrorStream()
->
getOutputStream()
->
setRequestProperty()
->
getRequestProperty()
->
getRequestProperties()
->
disconnect()
- Indicates that other requests to the server->
setChunkedStreamingMode()
- This method is used to enable streaming of a HTTP request body
URLConnection::guessContentTypeFromStream(php\io\Stream $stream): string
Tries to determine the type of an input stream based on the
characters at the beginning of the input stream. This method can
be used by subclasses that override the
getContentType
method.
URLConnection::guessContentTypeFromName(string $name): string
URLConnection::create(string $url, php\net\Proxy $proxy): URLConnection
URLConnection::enableSSLVerificationForHttps(): void
Enable checking ssl for https
URLConnection::disableSSLVerificationForHttps(): void
Disable checking ssl for https
__construct(php\net\URLConnection $parent): void
connect(): void
Opens a communications link to the resource referenced by this URL, if such a connection has not already been established.
getHeaderField(string $name): void
getHeaderFields(): array
getInputStream(): Stream
getErrorStream(): Stream
getOutputStream(): Stream
setRequestProperty(string $name, string $value): void
getRequestProperty(string $name): void
getRequestProperties(): array
disconnect(): void
Indicates that other requests to the server are unlikely in the near future. Calling disconnect() should not imply that this HttpURLConnection instance can be reused for other requests.
setChunkedStreamingMode(int $chunklen): void
This method is used to enable streaming of a HTTP request body without internal buffering, when the content length is not known in advance. In this mode, chunked transfer encoding is used to send the request body. Note, not all HTTP servers support this mode.