private function TimeRangeFormatter::getTimeDescription in Time Field For Drupal 8.x / 9.x 8
Same name and namespace in other branches
- 2.x src/Plugin/Field/FieldFormatter/TimeRangeFormatter.php \Drupal\time_field\Plugin\Field\FieldFormatter\TimeRangeFormatter::getTimeDescription()
Description of the time field.
Return value
string Description of the time field.
1 call to TimeRangeFormatter::getTimeDescription()
- TimeRangeFormatter::settingsForm in src/
Plugin/ Field/ FieldFormatter/ TimeRangeFormatter.php - Returns a form to configure settings for the formatter.
File
- src/
Plugin/ Field/ FieldFormatter/ TimeRangeFormatter.php, line 97
Class
- TimeRangeFormatter
- Plugin implementation of the 'time_formatter' formatter.
Namespace
Drupal\time_field\Plugin\Field\FieldFormatterCode
private function getTimeDescription() {
$output = '';
$output .= $this
->t('a - Lowercase am or pm') . '<br/>';
$output .= $this
->t('A - Uppercase AM or PM') . '<br/>';
$output .= $this
->t('B - Swatch Internet time (000 to 999)') . '<br/>';
$output .= $this
->t('g - 12-hour format of an hour (1 to 12)') . '<br/>';
$output .= $this
->t('G - 24-hour format of an hour (0 to 23)') . '<br/>';
$output .= $this
->t('h - 12-hour format of an hour (01 to 12)') . '<br/>';
$output .= $this
->t('H - 24-hour format of an hour (00 to 23)') . '<br/>';
$output .= $this
->t('i - Minutes with leading zeros (00 to 59)') . '<br/>';
$output .= $this
->t('s - Seconds, with leading zeros (00 to 59)') . '<br/>';
return $output;
}