HTTPRequest
in package
implements
DOMWriterInterface
FinalYes
Legacy HTTP request model that can expose request data as DOM.
Included for historical compatibility only. This API is deprecated and should not be used in new code.
Tags
Table of Contents
Interfaces
- DOMWriterInterface
Constants
- METHOD_GET : mixed = 'GET'
- METHOD_HEAD : mixed = 'HEAD'
- METHOD_OPTIONS : mixed = 'OPTIONS'
- METHOD_POST : mixed = 'POST'
- PROTOCOL_HTTP : mixed = 'HTTP'
Properties
- $clientAgent : mixed
- $clientHost : mixed
- $clientIp : mixed
- $dict : mixed
- $input : mixed
- $method : mixed
- $mode : mixed
- $path : mixed
- $protocolMajorVersion : mixed
- $protocolMinorVersion : mixed
- $protocolName : mixed
- $protocolRecognised : mixed
- $schema : mixed
- $time : mixed
- $timeFloat : float
- $headerList : mixed
Methods
- __construct() : mixed
- asNode() : DOMElement
- getBody() : false|string
- getBodyJSON() : mixed
- getHeader() : mixed
- getInput() : false|string
- getInputJSON() : mixed
- getInputValue() : mixed
- getQuery() : string
- getURL() : string
- hasInputValue() : bool
- init() : void
- prepareEnvironment() : void
- setAllHeaders() : void
- setInput() : void
- setInputValue() : void
- setMode() : void
- setPath() : void
- toDocument() : DOMDocument
- toElement() : DOMElement
- toFileName() : string
- toString() : string
Constants
METHOD_GET
public
mixed
METHOD_GET
= 'GET'
METHOD_HEAD
public
mixed
METHOD_HEAD
= 'HEAD'
METHOD_OPTIONS
public
mixed
METHOD_OPTIONS
= 'OPTIONS'
METHOD_POST
public
mixed
METHOD_POST
= 'POST'
PROTOCOL_HTTP
public
mixed
PROTOCOL_HTTP
= 'HTTP'
Properties
$clientAgent
public
mixed
$clientAgent
$clientHost
public
mixed
$clientHost
$clientIp
public
mixed
$clientIp
$dict
public
mixed
$dict
$input
public
mixed
$input
$method
public
mixed
$method
$mode
public
mixed
$mode
$path
public
mixed
$path
= '/'
$protocolMajorVersion
public
mixed
$protocolMajorVersion
$protocolMinorVersion
public
mixed
$protocolMinorVersion
$protocolName
public
mixed
$protocolName
$protocolRecognised
public
mixed
$protocolRecognised
$schema
public
mixed
$schema
$time
public
mixed
$time
$timeFloat
public
float
$timeFloat
$headerList
protected
mixed
$headerList
Methods
__construct()
public
__construct() : mixed
asNode()
public
asNode(DOMDocument $doc) : DOMElement
Parameters
- $doc : DOMDocument
Return values
DOMElementgetBody()
public
getBody() : false|string
Return values
false|stringgetBodyJSON()
public
getBodyJSON() : mixed
getHeader()
public
getHeader(string $key[, string|null $default = null ]) : mixed
Parameters
- $key : string
- $default : string|null = null
getInput()
public
getInput() : false|string
Return values
false|stringgetInputJSON()
public
getInputJSON() : mixed
getInputValue()
public
getInputValue(mixed $key[, mixed $val = null ]) : mixed
Parameters
- $key : mixed
- $val : mixed = null
getQuery()
public
getQuery() : string
Return values
stringgetURL()
public
getURL() : string
Return values
stringhasInputValue()
public
hasInputValue(mixed $key) : bool
Parameters
- $key : mixed
Return values
boolinit()
public
init(array<string|int, mixed> $env) : void
Parameters
- $env : array<string|int, mixed>
prepareEnvironment()
public
static prepareEnvironment(array<string|int, mixed> &$env) : void
Parameters
- $env : array<string|int, mixed>
setAllHeaders()
public
setAllHeaders(array<string|int, mixed> $headerList) : void
Parameters
- $headerList : array<string|int, mixed>
setInput()
public
setInput(array<string|int, mixed> $input) : void
Parameters
- $input : array<string|int, mixed>
setInputValue()
public
setInputValue(mixed $key[, mixed $val = null ]) : void
Parameters
- $key : mixed
- $val : mixed = null
setMode()
public
setMode(mixed $mode) : void
Parameters
- $mode : mixed
setPath()
public
setPath(mixed $path) : void
Parameters
- $path : mixed
toDocument()
public
toDocument() : DOMDocument
Return values
DOMDocumenttoElement()
public
toElement(DOMDocument $targetDoc) : DOMElement
Parameters
- $targetDoc : DOMDocument
Return values
DOMElementtoFileName()
public
toFileName() : string
Return values
stringtoString()
public
toString() : string