public function ParameterBag::getDigits in Zircon Profile 8
Same name and namespace in other branches
- 8.0 vendor/symfony/http-foundation/ParameterBag.php \Symfony\Component\HttpFoundation\ParameterBag::getDigits()
Returns the digits of the parameter value.
Parameters
string $key The parameter key:
mixed $default The default value if the parameter key does not exist:
bool $deep If true, a path like foo[bar] will find deeper items:
Return value
string The filtered value
File
- vendor/
symfony/ http-foundation/ ParameterBag.php, line 208
Class
- ParameterBag
- ParameterBag is a container for key/value pairs.
Namespace
Symfony\Component\HttpFoundationCode
public function getDigits($key, $default = '', $deep = false) {
// we need to remove - and + because they're allowed in the filter
return str_replace(array(
'-',
'+',
), '', $this
->filter($key, $default, $deep, FILTER_SANITIZE_NUMBER_INT));
}