class Request

Handles all kind of stuff during one request

Constants

GET

POST

PUT

DELETE

HEAD

Properties

bool $post
bool $get
bool $put
bool $delete

Methods

__construct()

Request constructor.

bool
accepts_html()

Returns true of the requesting browser accepts text/html as response mime type

bool
accepts_image()

Returns true of the requesting browser accepts image/* as response mime type

bool
accepts_json()

Returns true of the requesting browser accepts application/json as response mime type

bool
accepts_mime($accepted_mime_type)

Checks if the browser accepts the passed mime types for this request. Parameter can contain wildcards using fnmatch syntax $XF->lib->request->accepts_mime("text/*")

string
getMethod()

No description

get_input()

Read everything from STDIN e.g. for PUT Requests

mixed
get_var($var)

No description

bool
is_webservice_call(string $type = 'any')

No description

set_var($var, $value)

No description

Details

at line 43
__construct()

Request constructor.

at line 138
bool accepts_html()

Returns true of the requesting browser accepts text/html as response mime type

Return Value

bool

at line 146
bool accepts_image()

Returns true of the requesting browser accepts image/* as response mime type

Return Value

bool

at line 154
bool accepts_json()

Returns true of the requesting browser accepts application/json as response mime type

Return Value

bool

at line 124
bool accepts_mime($accepted_mime_type)

Checks if the browser accepts the passed mime types for this request. Parameter can contain wildcards using fnmatch syntax $XF->lib->request->accepts_mime("text/*")

Parameters

$accepted_mime_type

Return Value

bool

Returns true if the passed mime is accepted

at line 159
string getMethod()

No description

Return Value

string

at line 108
get_input()

Read everything from STDIN e.g. for PUT Requests

at line 67
mixed get_var($var)

No description

Parameters

$var

Return Value

mixed

at line 76
bool is_webservice_call(string $type = 'any')

No description

Parameters

string $type

Return Value

bool

at line 58
set_var($var, $value)

No description

Parameters

$var
$value