1 | <?php |
||
5 | class Input |
||
6 | { |
||
7 | |||
8 | /** |
||
9 | * indicates that the HTML input type is 'checkbox' |
||
10 | */ |
||
11 | public const TYPE_CHECKBOX = 'checkbox'; |
||
12 | |||
13 | /** |
||
14 | * indicates that the HTML input type is 'color' |
||
15 | */ |
||
16 | public const TYPE_COLOR = 'color'; |
||
17 | |||
18 | /** |
||
19 | * indicates that the HTML input type is 'file' |
||
20 | */ |
||
21 | public const TYPE_FILE = 'file'; |
||
22 | |||
23 | /** |
||
24 | * indicates that the HTML input type is 'hidden' |
||
25 | */ |
||
26 | public const TYPE_HIDDEN = 'hidden'; |
||
27 | |||
28 | /** |
||
29 | * indicates that the HTML input type is 'image' |
||
30 | */ |
||
31 | public const TYPE_IMAGE = 'image'; |
||
32 | |||
33 | /** |
||
34 | * indicates that the HTML input type is 'password' |
||
35 | */ |
||
36 | public const TYPE_PASSWORD = 'password'; |
||
37 | |||
38 | /** |
||
39 | * indicates that the HTML input type is 'radio' |
||
40 | */ |
||
41 | public const TYPE_RADIO = 'radio'; |
||
42 | |||
43 | /** |
||
44 | * indicates that the HTML input type is 'url' |
||
45 | */ |
||
46 | public const TYPE_URL = 'url'; |
||
47 | |||
48 | /** |
||
49 | * @var array |
||
50 | */ |
||
51 | private $valid_type_options; |
||
52 | |||
53 | |||
54 | public function __construct() |
||
70 | |||
71 | |||
72 | /** |
||
73 | * @param bool $constants_only |
||
74 | * @return array |
||
75 | */ |
||
76 | public function validTypeOptions(bool $constants_only = false): array |
||
82 | } |
||
83 |