Baigudin Software avatar
Baigudin Software logo
home
ru region
en region

PHP DOM Builder API

We have participated in OS DAY 2017 conference

The Baigudin Software Company has participated in OS DAY – a fourth scientific-practical conference, which aims to determine a mission of Russia in developing sphere of operating systems.

Class «DomBuilder\Element\Input\File»

input type=file – file upload control.

The input element with a type attribute whose value is "file" represents a list of file items, each consisting of a file name, a file type, and a file body (the contents of the file).

All implemented interfaces:

Object Builder Property Attribute Traverse Fetch Search Tester Field

public \StdClass file();

Returns checked uploaded file information.

Method returns a file information which gets after checking.

Returns:
\StdClass — file information.

public int|File fileMaxSize(int $size=NULL);

Returns or sets available maximum rage size for file size.

Parameters:
int $size — maximum size in byte.

Returns:
int|File — a current value or this element.

public int|File fileMinSize(int $size=NULL);

Returns or sets available minimum rage size for file size.

Parameters:
int $size — minimum size in byte.

Returns:
int|File — a current value or this element.

public File fileSize(int $min, int $max);

Sets an available rage for file size.

Parameters:
int $min — minimum size in byte.
int $max — maximum size in byte.

Returns:
File — this element.

public \StdClass value(mixed $value=NULL, string $lang=NULL);

Returns unchecked uploaded file information.

The method returns uploaded file information in StdClass object which contains a name, path, type, and size fields.

Parameters:
mixed $value — always should be NULL.
string $lang — always should be NULL.

Returns:
\StdClass — file information.

Back to class list