Request GLOBAL vars

Request returns $_GLOBAL variables, f.ex.

$_POST = [
    'id' => 12,
    'name' => 'Hans',
    'age' => 50
];
Request::post('id'); 
// Return single GET value '12'
Request::post('id', 'name');
// Return partia GET array {"id":12,"name":"Hans"}
Request::post();
// Return complete POST array {"id":12,"name":"Hans","age":50}
MethodReturn value

Request::get()

$_GET

Request::get('id')

$_GET['id']

Request::post()

$_POST

Request::cookie()

$_COOKIE

Last updated