\rex_context

A generic implementiation of rex_context_provider.

Summary

Methods
Properties
Constants
__construct()
getUrl()
setParam()
getParam()
getHiddenInputFields()
restore()
fromGet()
fromPost()
No public properties found
No constants found
No protected methods found
No protected properties found
N/A
No private methods found
No private properties found
N/A

Methods

__construct()

__construct(array  $globalParams = []) : mixed

Constructs a rex_context with the given global parameters.

Parameters

array $globalParams

A array containing only scalar values for key/value

Returns

mixed —

getUrl()

getUrl(array  $params = [], mixed  $escape = true) : mixed

{@inheritdoc}

Parameters

array $params
mixed $escape

Returns

mixed —

setParam()

setParam(string  $name, mixed  $value) : mixed

Set a global parameter.

Parameters

string $name
mixed $value

Returns

mixed —

getParam()

getParam(string  $name, mixed  $default = null) : mixed

Returns the value associated with the given parameter $name.

When no value is set, $default will be returned.

Parameters

string $name
mixed $default

Returns

mixed —

getHiddenInputFields()

getHiddenInputFields(array  $params = []) : string

Returns a html string containg hidden input fields for the given parameters.

Parameters

array $params

A array containing key value pairs for the parameter and its value

Returns

string —

The generated html source containing the hidden input fields

restore()

restore() : self

Returns a rex_context instance containing all GET and POST parameters.

Returns

self —

fromGet()

fromGet() : self

Returns a rex_context instance containing all GET parameters.

Returns

self —

fromPost()

fromPost() : self

Returns a rex_context instance containing all POST parameters.

Returns

self —