Feature #14894
closedstdWrap.age should differenciate between singular/plural
0%
Description
The .age stdWrap parameter currently only allows us to specify " min| hrs| days| yrs", which will also show plural text if we have a quantity of "1". The attached patch (for typo3/sysext/cms/tslib/class.tslib_content.php) changes the possible value of the .age setting to allow 8 values:
" min| hrs| days| yrs| min| hour| day| year"
The second set is the singular variant. So we can have outputs like "1 hour" and "1 year". It remains backwards compatible, in that older TYPO3 (with newer TypoScript) will still show the "good-old" plural variants.
In a remote future this text should become language-dependent, so that we have different outputs depending on the language of the site. This should also be prepared for situations where not always is the "1" unit singular and all others plural. There are languages where there are other rules for plurals (see gettext, PO-setting "Plural-Forms").
(issue imported from #M1333)
Files