public function TranslatableMarkup::getOption in Drupal 10
Same name and namespace in other branches
- 8 core/lib/Drupal/Core/StringTranslation/TranslatableMarkup.php \Drupal\Core\StringTranslation\TranslatableMarkup::getOption()
- 9 core/lib/Drupal/Core/StringTranslation/TranslatableMarkup.php \Drupal\Core\StringTranslation\TranslatableMarkup::getOption()
Gets a specific option from this translated string.
Parameters
string $name: Option name.
Return value
mixed The value of this option or empty string of option is not set.
File
- core/
lib/ Drupal/ Core/ StringTranslation/ TranslatableMarkup.php, line 158
Class
- TranslatableMarkup
- Provides translatable markup class.
Namespace
Drupal\Core\StringTranslationCode
public function getOption($name) {
return $this->options[$name] ?? '';
}