In pickadatejs
, is it possible to get lowercase format (am/pm) instead of uppercase format (AM/PM), with minimum configuration as possible?
Asked
Active
Viewed 704 times
-2
-
2It's in the documentation http://amsul.ca/pickadate.js/time/#formats – Sterling Archer Apr 12 '16 at 03:23
-
1Could also just use CSS `text-transform: lowercase` on the am/pm text. – Patrik Affentranger Apr 12 '16 at 03:44
1 Answers
0
From the docs:
The formatLabel option is unique. It can contain HTML and it can also be a function if you want to create the label during run-time:
$('.timepicker').pickatime({
// Escape any “rule” characters with an exclamation mark (!).
format: 'T!ime selected: h:i a',
formatLabel: '<b>h</b>:i <!i>a</!i>',
formatSubmit: 'HH:i',
hiddenPrefix: 'prefix__',
hiddenSuffix: '__suffix'
})
In formatLabel, you can simply use .toLowerCase()
, since it accepts a function.

omarjmh
- 13,632
- 6
- 34
- 42