**Problem**
The "Expiration" field on [[ https://www.mediawiki.org/wiki/Help:Blocking_users | Special:Block ]] only accepts English input.
The select box has several options, the values must be in English because that is all [[ https://secure.php.net/manual/en/function.strtotime.php | strtotime() ]] supports.
This means that the label can be translated into the wiki's language, but the value is in English:
https://de.wikipedia.org/wiki/MediaWiki:Ipboptions
If a user goes to: https://de.wikipedia.org/wiki/Spezial:Sperren but their language is set to something other than `de` they will continue to see the labels in `de`
What's worse, the "Other time" option gives a text field and that text field can only accept input in English.
See T132220#4066969
Another problem is that if you are changing an existing block, the datetime that is displayed (from the database) is only in an English format. And the DateTimeInputWidget has to change it's [[ https://en.wikipedia.org/wiki/ISO_8601 ]] format to an English-only [[ https://tools.ietf.org/html/rfc2822 | RFC 2822 ]] format. See T132220#4130623
**Solution**
The values should be [[ https://en.wikipedia.org/wiki/ISO_8601#Time_intervals | ISO 8601 Time Interval ]] Durations, but the labels should be translatable (into any language, not just the language of the wiki). For instance, in code we should take the time intervals and transfer them into a string like `$1 days` which can then be translated into the user's preferred language.
The "Other" field should expose 2 more fields (instead of just 1). The first would be a number input and the second would be a drop down with units (i.e. "days", "weeks", "years", etc.) which would also be translated into the user's preferred translation.
This change would break any options specified in https://de.wikipedia.org/wiki/MediaWiki:Ipboptions we should mitigate this by creating an update script that would transfer the options into [[ https://en.wikipedia.org/wiki/ISO_8601#Time_intervals | ISO 8601 Time Interval ]] Durations (and remove the translations). We should also allow for them to specify other options like "indefinite" but this would just use a translation key rather than have the translation itself within the option.
When switching between the two fields (or changing an existing block), we'll have to round a precise date to a relative date (or display the DateTimeInput Widget as the default when changing a block)