protected function ElementBase::setProperty in Form Builder 7.2
Set the value of a property.
This method must update the $element for rendering as well as for later storage.
Parameters
string $property: Key of the property.
mixed $value: New value for the property.
1 call to ElementBase::setProperty()
- ElementBase::configurationSubmit in src/
ElementBase.php - Submit handler for the configuration form.
1 method overrides ElementBase::setProperty()
- Element::setProperty in modules/
webform/ src/ Element.php - Set the value of a property.
File
- src/
ElementBase.php, line 65
Class
Namespace
Drupal\form_builderCode
protected function setProperty($property, $value) {
// Remove empty properties entirely.
if ($value === '' || is_null($value)) {
unset($this->element['#' . $property]);
}
else {
$this->element['#' . $property] = $value;
}
}