/**
* Gets a value from the input data.
*
* @param string $name The name of the input property (usually the name of the files INPUT tag) to get.
* @param mixed $default The default value to return if the named property does not exist.
* @param string $filter The filter to apply to the value.
*
* @return mixed The filtered input value.
*
* @see InputFilter::clean()
* @since 1.7.0
* @deprecated 5.0 Use Joomla\Input\Files instead
*/
public function get($name, $default = null, $filter = 'cmd')
{
if (isset($this->data[$name])) {
$results = $this->decodeData(array($this->data[$name]['name'], $this->data[$name]['type'], $this->data[$name]['tmp_name'], $this->data[$name]['error'], $this->data[$name]['size']));
// Prevent returning an unsafe file unless specifically requested
if (strtoupper($filter) !== 'RAW') {
$isSafe = InputFilter::isSafeFile($results);
if (!$isSafe) {
return $default;
}
}
return $results;
}
return $default;
}