Opened 12 years ago
Closed 11 years ago
#31121 closed defect (bug) (fixed)
Add leading zeros to 24 hour date formats
| Reported by: | iseulde | Owned by: | dd32 |
|---|---|---|---|
| Priority: | normal | Milestone: | 4.2 |
| Component: | General | Version: | |
| Severity: | normal | Keywords: | has-patch commit |
| Cc: | Focuses: |
Description
There are a lot of occurrences in core where we use G:i for a 24 hour time format. This leads to weird things like 0:11 and 1:22:33. In general we should never use the G for displaying dates. g should be used for 12 hour time formats since it's a value between 1 and 12. Either it's H:i or g:i.
Attachments (1)
Change History (7)
#2
@
12 years ago
- Keywords dev-feedback added
- Owner set to
- Status new → reviewing
@dd32: Have an opinion one way or the other?
#3
@
12 years ago
- Keywords dev-feedback removed
Agreed. We should only be using either of:
H:i - [00-23]:[00-59]g:i a - [1-12]:[00-59] [am-pm]
which the patch does, I also agree on a space between minutes and the meridiem
The following shouldn't be used:
h - [0-23]G - [00-12](especially not without the meridiem specified)
This ticket was mentioned in Slack in #core by drew. View the logs.
11 years ago
Note:
See TracTickets
for help on using tickets.
![(please configure the [header_logo] section in trac.ini)](/chrome/site/your_project_logo.png)
Also added a space for
g:iaand decapitalisedg:i Asince we useaeverywhere else.