TYPO3 CMS
TYPO3_6-2
Main Page
Related Pages
+
Classes
Class List
Class Index
Class Hierarchy
+
Class Members
+
All
$
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
+
Functions
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
+
Variables
$
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
r
s
t
u
v
w
+
Files
File List
+
File Members
+
All
$
(
_
a
c
d
e
f
h
i
l
o
p
r
s
t
u
x
+
Functions
_
a
c
d
e
f
i
l
o
p
r
s
u
x
+
Variables
$
(
_
a
d
e
h
i
p
r
s
t
Examples
•
All
Classes
Namespaces
Files
Functions
Variables
Pages
ButtonElement.php
Go to the documentation of this file.
1
<?php
2
namespace
TYPO3\CMS\Form\Domain\Model\Element
;
3
22
class
ButtonElement
extends
\TYPO3\CMS\Form\Domain\Model\Element\AbstractElement
{
23
29
protected
$allowedAttributes
= array(
30
'accesskey'
=>
''
,
31
'alt'
=>
''
,
32
'class'
=>
''
,
33
'dir'
=>
''
,
34
'disabled'
=>
''
,
35
'id'
=>
''
,
36
'lang'
=>
''
,
37
'name'
=>
''
,
38
'style'
=>
''
,
39
'tabindex'
=>
''
,
40
'title'
=>
''
,
41
'type'
=>
'button'
,
42
'value'
=>
''
43
);
44
50
protected
$mandatoryAttributes
= array(
51
'name'
,
52
'id'
53
);
54
65
public
function
setValue
(
$value
=
''
) {
67
$localizationHandler =
\TYPO3\CMS\Core\Utility\GeneralUtility::makeInstance
(
'TYPO3\\CMS\\Form\\Localization'
);
68
$oldValue = $this->
getAttributeValue
(
'value'
);
69
if
(empty($oldValue)) {
70
if
(!empty(
$value
)) {
71
$newValue = (string)
$value
;
72
}
else
{
73
$newValue = $localizationHandler->getLocalLanguageLabel(
'tx_form_domain_model_element_button.value'
);
74
}
75
$this->value = (string) $newValue;
76
$this->
setAttribute
(
'value'
, $newValue);
77
}
78
}
79
80
}
TYPO3\CMS\Form\Domain\Model\Element\AbstractElement\setValue
setValue($value='')
Definition:
AbstractElement.php:383
TYPO3\CMS\Form\Domain\Model\Element\ButtonElement
Definition:
ButtonElement.php:22
TYPO3\CMS\Form\Domain\Model\Element\AbstractElement
Definition:
AbstractElement.php:22
TYPO3\CMS\Form\Domain\Model\Element\AbstractElement\getAttributeValue
getAttributeValue($key)
Definition:
AbstractElement.php:315
TYPO3\CMS\Core\Utility\GeneralUtility\makeInstance
static makeInstance($className)
Definition:
GeneralUtility.php:4424
TYPO3\CMS\Form\Domain\Model\Element\AbstractElement\setAttribute
setAttribute($attribute, $value)
Definition:
AbstractElement.php:238
TYPO3\CMS\Form\Domain\Model\Element\ButtonElement\$allowedAttributes
$allowedAttributes
Definition:
ButtonElement.php:29
TYPO3\CMS\Form\Domain\Model\Element\ButtonElement\$mandatoryAttributes
$mandatoryAttributes
Definition:
ButtonElement.php:50
TYPO3\CMS\Form\Domain\Model\Element\AbstractElement\$value
$value
Definition:
AbstractElement.php:91
TYPO3\CMS\Form\Domain\Model\Element
Definition:
AbstractElement.php:2
typo3
sysext
form
Classes
Domain
Model
Element
ButtonElement.php
Generated on Wed Aug 7 2019 09:52:27 for TYPO3 CMS by
1.8.13