Skip to content

Minor tweaks in the Timezone validator docs #11402

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Apr 11, 2019
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 7 additions & 6 deletions reference/constraints/Timezone.rst
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ string meant to contain a timezone identifier (e.g. ``America/New_York``):
/**
* @Assert\Timezone
*/
protected $timezone;
protected $timezone;
}

.. code-block:: yaml
Expand Down Expand Up @@ -125,12 +125,13 @@ identifiers to the ones that belong to that geographical zone:
* ``\DateTimeZone::INDIAN``
* ``\DateTimeZone::PACIFIC``

The special ``\DateTimeZone::ALL`` zone accepts any timezone excluding deprecated timezones.

The special ``\DateTimeZone::ALL_WITH_BC`` zone accepts any timezone including deprecated timezones.
In addition, there are some special zone values:

The special ``\DateTimeZone::PER_COUNTRY`` zone limits the timezones to a certain country. This zone
value must be used in combination with the ``countryCode`` option.
* ``\DateTimeZone::ALL`` accepts any timezone excluding deprecated timezones;
* ``\DateTimeZone::ALL_WITH_BC`` accepts any timezone including deprecated
timezones;
* ``\DateTimeZone::PER_COUNTRY`` restricts the valid timezones to a certain
country (which is defined using the ``countryCode`` option).

countryCode
~~~~~~~~~~~
Expand Down