Skip to content

Commit 61ac24c

Browse files
committed
Lots of fixes
1 parent f7dcfa5 commit 61ac24c

File tree

1 file changed

+11
-11
lines changed

1 file changed

+11
-11
lines changed

reference/constraints/Hostname.rst

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,9 @@
11
Hostname
22
========
33

4-
This constraint ensures that the given value is a valid and non-reserved
5-
host name (internally it uses the ``FILTER_VALIDATE_DOMAIN`` option of the
6-
:phpfunction:`filter_var` PHP function).
4+
This constraint ensures that the given value is a valid host name (internally it
5+
uses the ``FILTER_VALIDATE_DOMAIN`` option of the :phpfunction:`filter_var` PHP
6+
function).
77

88
.. versionadded:: 5.1
99

@@ -29,7 +29,7 @@ will contain a host name.
2929

3030
.. code-block:: php-annotations
3131
32-
// src/Entity/Server.php
32+
// src/Entity/ServerSettings.php
3333
namespace App\Entity;
3434
3535
use Symfony\Component\Validator\Constraints as Assert;
@@ -86,9 +86,9 @@ will contain a host name.
8686
}
8787
}
8888
89-
The following TLD are reserved according to `RFC 2606`_ and that's why hostnames
90-
containing them are not considered valid: ``.example``, ``.invalid``, ``.localhost``,
91-
``.test``.
89+
The following top-level domains (TLD) are reserved according to `RFC 2606`_ and
90+
that's why hostnames containing them are not considered valid: ``.example``,
91+
``.invalid``, ``.localhost``, and ``.test``.
9292

9393
.. include:: /reference/constraints/_empty-values-are-valid.rst.inc
9494

@@ -120,16 +120,16 @@ Parameter Description
120120
**type**: ``bool`` **default**: ``true``
121121

122122
By default, hostnames are considered valid only when they are fully qualified
123-
and include the their TLDs (top-level domain names). For instance,
124-
``example.com`` is valid by ``example`` is not.
123+
and include their TLDs (top-level domain names). For instance, ``example.com``
124+
is valid but ``example`` is not.
125125

126126
Set this option to ``false`` to not require any TLD in the hostnames.
127127

128128
.. note::
129129

130130
This constraint does not validate that the given TLD value is included in
131131
the `list of official top-level domains`_ (because that list is growing
132-
continuously and it's nearly impossible to keep track of it).
132+
continuously and it's hard to keep track of it).
133133

134134
.. _`RFC 2606`: https://tools.ietf.org/html/rfc2606
135-
.. _`full list of official top-level domains`: https://en.wikipedia.org/wiki/List_of_Internet_top-level_domains
135+
.. _`list of official top-level domains`: https://en.wikipedia.org/wiki/List_of_Internet_top-level_domains

0 commit comments

Comments
 (0)