public function file_error_message( $key ) {
		if ( $this->file_info( $key ) ) {
			return '';
		} elseif ( ! isset( $_FILES[ $key ] ) ) {
			return $this->__( 'File is not specified.' );
		} else {
			switch ( $_FILES[ $key ]['error'] ) {
				case UPLOAD_ERR_FORM_SIZE:
				case UPLOAD_ERR_INI_SIZE:
					return $this->__( 'Uploaded file size exceeds allowed limit.' );
					break;
				default:
					return $this->__( 'Failed to upload' );
					break;
			}
		}
	}
public function file_error_message( $key ) {
		if ( $this->file_info( $key ) ) {
			return '';
		} elseif ( ! isset( $_FILES[ $key ] ) ) {
			return $this->__( 'File is not specified.' );
		} else {
			switch ( $_FILES[ $key ]['error'] ) {
				case UPLOAD_ERR_FORM_SIZE:
				case UPLOAD_ERR_INI_SIZE:
					return $this->__( 'Uploaded file size exceeds allowed limit.' );
					break;
				default:
					return $this->__( 'Failed to upload' );
					break;
			}
		}
	}
public function file_error_message ( $ key ) { if ( $ this -> file_info ( $ key ) ) { return '' ; } elseif ( ! isset ( $ _FILES [ $ key ] ) ) { return $ this -> __ ( 'File is not specified.' ) ; } else { switch ( $ _FILES [ $ key ] [ 'error' ] ) { case UPLOAD_ERR_FORM_SIZE : case UPLOAD_ERR_INI_SIZE : return $ this -> __ ( 'Uploaded file size exceeds allowed limit.' ) ; break ; default : return $ this -> __ ( 'Failed to upload' ) ; break ; } } }
Get file upload error message

@param string $key

@return string
Get file upload error message