public function WebformElementBase::formatText in Webform 8.5
Same name and namespace in other branches
- 6.x src/Plugin/WebformElementBase.php \Drupal\webform\Plugin\WebformElementBase::formatText()
Format an element's value as plain text.
Parameters
array $element: An element.
\Drupal\webform\WebformSubmissionInterface $webform_submission: A webform submission.
array $options: An array of options.
Return value
array|string The element's value formatted as plain text or a render array.
Overrides WebformElementInterface::formatText
4 calls to WebformElementBase::formatText()
- DateBase::buildExportRecord in src/
Plugin/ WebformElement/ DateBase.php - Build an element's export row.
- WebformCompositeBase::formatText in src/
Plugin/ WebformElement/ WebformCompositeBase.php - Format an element's value as plain text.
- WebformElementBase::buildExportRecord in src/
Plugin/ WebformElementBase.php - Build an element's export row.
- WebformSignature::buildExportRecord in src/
Plugin/ WebformElement/ WebformSignature.php - Build an element's export row.
2 methods override WebformElementBase::formatText()
- WebformCompositeBase::formatText in src/
Plugin/ WebformElement/ WebformCompositeBase.php - Format an element's value as plain text.
- WebformTestElement::formatText in tests/
modules/ webform_test_element/ src/ Plugin/ WebformElement/ WebformTestElement.php - Format an element's value as plain text.
File
- src/
Plugin/ WebformElementBase.php, line 1383
Class
- WebformElementBase
- Provides a base class for a webform element.
Namespace
Drupal\webform\PluginCode
public function formatText(array $element, WebformSubmissionInterface $webform_submission, array $options = []) {
return $this
->format('Text', $element, $webform_submission, $options);
}