protected function HtmlMailTestForm::getOptions in HTML Mail 8
Same name and namespace in other branches
- 8.3 src/Form/HtmlMailTestForm.php \Drupal\htmlmail\Form\HtmlMailTestForm::getOptions()
Returns a list with all mail plugins.
Return value
string[] List of mail plugin labels, keyed by ID.
1 call to HtmlMailTestForm::getOptions()
- HtmlMailTestForm::buildForm in src/
Form/ HtmlMailTestForm.php - Form constructor.
File
- src/
Form/ HtmlMailTestForm.php, line 136
Class
- HtmlMailTestForm
- Class HtmlMailTestForm.
Namespace
Drupal\htmlmail\FormCode
protected function getOptions() {
$list = [];
// Append all MailPlugins.
foreach ($this->mailManager
->getDefinitions() as $definition) {
$list[$definition['id']] = $definition['label'];
}
if (empty($list)) {
$list['htmlmail'] = 'HTMLMailSystem';
}
return $list;
}