function hasUpload($name) {
		// if information about the specified file upload is available
		if (isset($_FILES[$name])) {
			// if the file input had an array-style name
			if (\is_array($_FILES[$name]['error'])) {
				// for any file selected from this input
				foreach ($_FILES[$name]['error'] as $errorCode) {
					if ($errorCode !== \UPLOAD_ERR_NO_FILE) {
						return true;
					}
				}
			}
			// if the file input had a scalar-style name
			else {
				return $_FILES[$name]['error'] !== \UPLOAD_ERR_NO_FILE;
			}
		}

		return false;
	}
function hasUpload($name) {
		// if information about the specified file upload is available
		if (isset($_FILES[$name])) {
			// if the file input had an array-style name
			if (\is_array($_FILES[$name]['error'])) {
				// for any file selected from this input
				foreach ($_FILES[$name]['error'] as $errorCode) {
					if ($errorCode !== \UPLOAD_ERR_NO_FILE) {
						return true;
					}
				}
			}
			// if the file input had a scalar-style name
			else {
				return $_FILES[$name]['error'] !== \UPLOAD_ERR_NO_FILE;
			}
		}

		return false;
	}
function hasUpload ( $ name ) { // if information about the specified file upload is available if ( isset ( $ _FILES [ $ name ] ) ) { // if the file input had an array-style name if ( \ is_array ( $ _FILES [ $ name ] [ 'error' ] ) ) { // for any file selected from this input foreach ( $ _FILES [ $ name ] [ 'error' ] as $ errorCode ) { if ( $ errorCode !== \ UPLOAD_ERR_NO_FILE ) { return true ; } } } // if the file input had a scalar-style name else { return $ _FILES [ $ name ] [ 'error' ] !== \ UPLOAD_ERR_NO_FILE ; } } return false ; }
Returns whether the specified file upload has been sent with the current request

@param string $name the name of the file upload, i.e. usually the name of the HTML input field
@return bool
Returns whether the specified file upload has been sent with the current request