PHP 7.2.7 Released


(PECL pecl_http >= 0.22.0)

HttpQueryString::getGet (part of) query string


public mixed HttpQueryString::get ([ string $key [, mixed $type = 0 [, mixed $defval = NULL [, bool $delete = false ]]]] )

Get (part of) the query string.

The type parameter is either one of the HttpQueryString::TYPE_* constants or a type abbreviation like "b" for bool, "i" for int, "f" for float, "s" for string, "a" for array and "o" for a stdClass object.



key of the query string param to retrieve


which variable type to enforce


default value if key does not exist


whether to remove the key/value pair from the query string

Return Values

Returns the value of the query string param or the whole query string if no key was specified on success or defval if key does not exist.

add a note add a note

User Contributed Notes

There are no user contributed notes for this page.
To Top