Documentation

function_rex_globals.php

Getter functions for the superglobals.

Table of Contents

Functions

rex_get()  : mixed
Returns the variable $varname of $_GET and casts the value.
rex_post()  : mixed
Returns the variable $varname of $_POST and casts the value.
rex_request()  : mixed
Returns the variable $varname of $_REQUEST and casts the value.
rex_server()  : mixed
Returns the variable $varname of $_SERVER and casts the value.
rex_session()  : mixed
Returns the variable $varname of $_SESSION and casts the value.
rex_set_session()  : void
Sets a session variable.
rex_unset_session()  : void
Deletes a session variable.
rex_cookie()  : mixed
Returns the variable $varname of $_COOKIE and casts the value.
rex_files()  : mixed
Returns the variable $varname of $_FILES and casts the value.
rex_env()  : mixed
Returns the variable $varname of $_ENV and casts the value.
rex_request_method()  : string
Returns the HTTP method of the current request.

Functions

rex_get()

Returns the variable $varname of $_GET and casts the value.

rex_get(string $varname[, mixed $vartype = '' ][, mixed $default = '' ]) : mixed
Parameters
$varname : string

Variable name

$vartype : mixed = ''

Variable type

$default : mixed = ''

Default value

Tags
psalm-taint-escape

($vartype is 'bool'|'boolean'|'int'|'integer'|'double'|'float'|'real' ? 'html' : null)

see
rex_request::get()

rex_post()

Returns the variable $varname of $_POST and casts the value.

rex_post(string $varname[, mixed $vartype = '' ][, mixed $default = '' ]) : mixed
Parameters
$varname : string

Variable name

$vartype : mixed = ''

Variable type

$default : mixed = ''

Default value

Tags
psalm-taint-escape

($vartype is 'bool'|'boolean'|'int'|'integer'|'double'|'float'|'real' ? 'html' : null)

see
rex_request::post()

rex_request()

Returns the variable $varname of $_REQUEST and casts the value.

rex_request(string $varname[, mixed $vartype = '' ][, mixed $default = '' ]) : mixed
Parameters
$varname : string

Variable name

$vartype : mixed = ''

Variable type

$default : mixed = ''

Default value

Tags
psalm-taint-escape

($vartype is 'bool'|'boolean'|'int'|'integer'|'double'|'float'|'real' ? 'html' : null)

see
rex_request::request()

rex_server()

Returns the variable $varname of $_SERVER and casts the value.

rex_server(string $varname[, mixed $vartype = '' ][, mixed $default = '' ]) : mixed
Parameters
$varname : string

Variable name

$vartype : mixed = ''

Variable type

$default : mixed = ''

Default value

Tags
see
rex_request::server()

rex_session()

Returns the variable $varname of $_SESSION and casts the value.

rex_session(string $varname[, mixed $vartype = '' ][, mixed $default = '' ]) : mixed
Parameters
$varname : string

Variable name

$vartype : mixed = ''

Variable type

$default : mixed = ''

Default value

Tags
throws
rex_exception
see
rex_request::session()

Returns the variable $varname of $_COOKIE and casts the value.

rex_cookie(string $varname[, mixed $vartype = '' ][, mixed $default = '' ]) : mixed
Parameters
$varname : string

Variable name

$vartype : mixed = ''

Variable type

$default : mixed = ''

Default value

Tags
psalm-taint-escape

($vartype is 'bool'|'boolean'|'int'|'integer'|'double'|'float'|'real' ? 'html' : null)

see
rex_request::cookie()

rex_files()

Returns the variable $varname of $_FILES and casts the value.

rex_files(string $varname[, mixed $vartype = '' ][, mixed $default = '' ]) : mixed
Parameters
$varname : string

Variable name

$vartype : mixed = ''

Variable type

$default : mixed = ''

Default value

Tags
see
rex_request::files()

rex_env()

Returns the variable $varname of $_ENV and casts the value.

rex_env(string $varname[, mixed $vartype = '' ][, mixed $default = '' ]) : mixed
Parameters
$varname : string

Variable name

$vartype : mixed = ''

Variable type

$default : mixed = ''

Default value

Tags
see
rex_request::env()

        
On this page

Search results