public function WebformAjaxElementTrait::buildAjaxElement in Webform 6.x
Same name and namespace in other branches
- 8.5 src/Element/WebformAjaxElementTrait.php \Drupal\webform\Element\WebformAjaxElementTrait::buildAjaxElement()
Build an Ajax element.
Parameters
string $id: The id used to create the Ajax wrapper and trigger.
array &$wrapper_element: The element to be update via Ajax.
array &$trigger_element: The element to trigger the Ajax update.
array|null &$update_element: The element to append the hidden Ajax submit button.
4 calls to WebformAjaxElementTrait::buildAjaxElement()
- OptionsLimitWebformHandler::buildConfigurationForm in modules/
webform_options_limit/ src/ Plugin/ WebformHandler/ OptionsLimitWebformHandler.php - Form constructor.
- WebformSubmissionExporter::buildExportOptionsForm in src/
WebformSubmissionExporter.php - Build export options webform.
- WebformSubmissionResendForm::buildForm in src/
Form/ WebformSubmissionResendForm.php - Form constructor.
- WebformTestElementProperties::form in tests/
modules/ webform_test_element/ src/ Plugin/ WebformElement/ WebformTestElementProperties.php - Gets the actual configuration webform array to be built.
File
- src/
Element/ WebformAjaxElementTrait.php, line 67
Class
- WebformAjaxElementTrait
- Trait for ajax element support.
Namespace
Drupal\webform\ElementCode
public function buildAjaxElement($id, array &$wrapper_element, array &$trigger_element, array &$update_element = NULL) {
static::buildAjaxElementWrapper($id, $wrapper_element);
static::buildAjaxElementTrigger($id, $trigger_element);
if ($update_element) {
static::buildAjaxElementUpdate($id, $update_element);
}
else {
static::buildAjaxElementUpdate($id, $wrapper_element);
}
}