add handling of file parameters
This commit is contained in:
parent
c906747e7a
commit
075f05aaf9
1 changed files with 16 additions and 0 deletions
|
@ -86,6 +86,22 @@ function getHeaderValue($headerName) {
|
|||
return $_SERVER[$headerName];
|
||||
}
|
||||
|
||||
function getFileParameter($parameterName) {
|
||||
return $_FILES[$parameterName];
|
||||
}
|
||||
|
||||
function getOptionalFileParameter($parameterName, $default = NULL) {
|
||||
$parameter = getFileParameter($parameterName);
|
||||
|
||||
return handleOptionalParameter($parameter, $default);
|
||||
}
|
||||
|
||||
function getMandatoryFileParameter($parameterName, $message = '', $json = false) {
|
||||
$parameter = getFileParameter($parameterName);
|
||||
|
||||
return handleMandatoryParameter($parameterName, $parameter, $message, $json);
|
||||
}
|
||||
|
||||
function getPostParameter($parameterName) {
|
||||
return $_POST[$parameterName];
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue