Magento Extensions Rating 2024
EXTENSIONS BY CATEGORY
B2B (Business-To-Business)
Blog
Customer
ERP (Enterprise Resource Planning)
Mega Menu
One Step Checkout
Order
POS (Point Of Sale)
Search
Shopping Cart
Sitemap
SEO
Social
Stock & Inventory Management
EXTENSIONS BY DEVELOPER
aheadWorks
Amasty
Boost My Shop
BSS Commerce
Magestore
MageWorx
Mirasvit
Templates Master
Wyomind
XTENTO
Magento 2 Documentation
Magento 2 Documentation
2.3
Documentation for Magento 2 CMS v2.3 (December 2018)
vendor
magento
framework
Data
Form
Element
Text.php
Go to the documentation of this file.
1
<?php
7
namespace
Magento\Framework\Data\Form\Element
;
8
9
use
Magento\Framework\Escaper
;
10
14
class
Text
extends
AbstractElement
15
{
22
public
function
__construct
(
23
Factory
$factoryElement,
24
CollectionFactory
$factoryCollection,
25
Escaper
$escaper,
26
$data
= []
27
) {
28
parent::__construct($factoryElement, $factoryCollection, $escaper,
$data
);
29
$this->
setType
(
'text'
);
30
$this->setExtType(
'textfield'
);
31
}
32
38
public
function
getHtml
()
39
{
40
$this->
addClass
(
'input-text admin__control-text'
);
41
return
parent::getHtml();
42
}
43
49
public
function
getHtmlAttributes
()
50
{
51
return
[
52
'type'
,
53
'title'
,
54
'class'
,
55
'style'
,
56
'onclick'
,
57
'onchange'
,
58
'onkeyup'
,
59
'disabled'
,
60
'readonly'
,
61
'maxlength'
,
62
'tabindex'
,
63
'placeholder'
,
64
'data-form-part'
,
65
'data-role'
,
66
'data-validation-params'
,
67
'data-action'
68
];
69
}
70
}
Magento\Framework\Data\Form\Element\CollectionFactory
Definition:
CollectionFactory.php:10
Magento\Framework\Data\Form\Element\Factory
Definition:
Factory.php:14
Magento\Framework\Escaper
Definition:
Escaper.php:15
Magento\Framework\Data\Form\Element\Text
Definition:
Text.php:14
$data
$data
Definition:
attribute_set_with_image_attribute.php:16
Magento\Framework\Data\Form\Element\AbstractElement\addClass
addClass($class)
Definition:
AbstractElement.php:257
Magento\Framework\Data\Form\Element\Text\getHtml
getHtml()
Definition:
Text.php:38
Magento\Framework\Data\Form\Element\Text\__construct
__construct(Factory $factoryElement, CollectionFactory $factoryCollection, Escaper $escaper, $data=[])
Definition:
Text.php:22
Magento\Framework\Data\Form\Element\AbstractElement\setType
setType($type)
Definition:
AbstractElement.php:197
Magento\Framework\Data\Form\Element
Definition:
AbstractElement.php:6
Magento\Framework\Data\Form\Element\Text\getHtmlAttributes
getHtmlAttributes()
Definition:
Text.php:49
Magento\Framework\Data\Form\Element\AbstractElement
Definition:
AbstractElement.php:21