Currently, the parser function has inconsistencies with major international standards, making its behavior unpredictable in various scenarios. This complicates the localization of dates. It is necessary to enable the functions to operate directly within date standards ISO/EDTF.
Description
Description
| Status | Subtype | Assigned | Task | ||
|---|---|---|---|---|---|
| Open | Feature | None | T382826 Add ISO/EDTF compliance mode to the #time parser function and mw.language:formatDate function | ||
| Open | None | T280510 Accept EDTF level 1 dates in the mediawiki time parser | |||
| Open | Feature | None | T381313 Support ISO date invervals in #time parser function | ||
| Open | None | T178175 {{#time}} parser function should not accept dates with zero in day or month positions | |||
| Open | None | T382829 Do not represent an ISO date without a day or day+month (YYYY-MM and YYYY) as a date with a day after conversion |
Event Timeline
Comment Actions
I would probably suggest doing this either as a new parser function, eg {{#timeiso}}, or as an explicit argument to the time function, eg {{#time:Y-m-d|2025-01-16|en||iso}}, rather than risk changing existing behaviors of {{#time}}. This also allows easier linting for "old" uses of {{#time}}.
Comment Actions
Yes, I completely agree that this should be a separate parser function or separate argument.
Comment Actions
Linked this topic in Community Wishlist wish: https://meta.wikimedia.org/wiki/Community_Wishlist/W345 :)