@@ -230,7 +230,7 @@ Usage of this string is the same as with variables and select::
230
230
231
231
You can also set an ``offset `` variable to determine whether the
232
232
pluralization should be offset (e.g. in sentences like ``You and # other people ``
233
- / ``You and # other person ``).
233
+ / ``You and # other person ``).
234
234
235
235
.. tip ::
236
236
@@ -239,23 +239,23 @@ Usage of this string is the same as with variables and select::
239
239
240
240
.. code-block :: text
241
241
242
- {gender_of_host, select,
242
+ {gender_of_host, select,
243
243
female {
244
- {num_guests, plural, offset:1
244
+ {num_guests, plural, offset:1
245
245
=0 {{host} does not give a party.}
246
246
=1 {{host} invites {guest} to her party.}
247
247
=2 {{host} invites {guest} and one other person to her party.}
248
248
other {{host} invites {guest} and # other people to her party.}}
249
249
}
250
250
male {
251
- {num_guests, plural, offset:1
251
+ {num_guests, plural, offset:1
252
252
=0 {{host} does not give a party.}
253
253
=1 {{host} invites {guest} to his party.}
254
254
=2 {{host} invites {guest} and one other person to his party.}
255
255
other {{host} invites {guest} and # other people to his party.}}
256
256
}
257
257
other {
258
- {num_guests, plural, offset:1
258
+ {num_guests, plural, offset:1
259
259
=0 {{host} does not give a party.}
260
260
=1 {{host} invites {guest} to their party.}
261
261
=2 {{host} invites {guest} and one other person to their party.}
@@ -377,7 +377,8 @@ using the :phpclass:`IntlDateFormatter`:
377
377
];
378
378
379
379
The "function statement" for the ``time `` and ``date `` functions can be one of
380
- short, medium, long or full, as documented on PHP.net::
380
+ ``short ``, ``medium ``, ``long `` or ``full ``, which correspond to the
381
+ `constants defined by the IntlDateFormatter class `_::
381
382
382
383
// prints "Published at Jan 25, 2019 - 11:30 AM"
383
384
echo $translator->trans('published_at', ['publication_date' => new \DateTime('2019-01-25 11:30:00')]);
@@ -439,3 +440,4 @@ The ``number`` formatter allows you to format numbers using Intl's :phpclass:`Nu
439
440
.. _`ICU MessageFormat` : http://userguide.icu-project.org/formatparse/messages
440
441
.. _`switch statement` : https://php.net/control-structures.switch
441
442
.. _`Language Plural Rules` : http://www.unicode.org/cldr/charts/latest/supplemental/language_plural_rules.html
443
+ .. _`constants defined by the IntlDateFormatter class` : https://php.net/manual/en/class.intldateformatter.php
0 commit comments