Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit6a375d6

Browse files
committed
document the2.5 validation options
1 parent7a0b1de commit6a375d6

File tree

1 file changed

+38
-1
lines changed

1 file changed

+38
-1
lines changed

‎reference/configuration/framework.rst‎

Lines changed: 38 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -55,6 +55,8 @@ Configuration
5555
* `cache`_
5656
* `enable_annotations`_
5757
* `translation_domain`_
58+
* `strict_email`_
59+
* `api`_
5860

5961
secret
6062
~~~~~~
@@ -532,7 +534,7 @@ cache
532534
**type**: ``string``
533535

534536
This value is used to determine the service that is used to persist class
535-
metadata in a cache. The actual service name is built byprefix the configured
537+
metadata in a cache. The actual service name is built byprefixing the configured
536538
value with ``validator.mapping.cache.`` (e.g. if the value is ``apc``, the
537539
``validator.mapping.cache.apc`` service will be injected). The service has
538540
to implement the:class:`Symfony\\Component\\Validator\\Mapping\\Cache\\CacheInterface`.
@@ -552,6 +554,41 @@ translation_domain
552554
The translation domain that is used when translating validation constraint
553555
error messages.
554556

557+
strict_email
558+
............
559+
560+
..versionadded::2.5
561+
The ``strict_email`` option was introduced in Symfony 2.5.
562+
563+
**type**: ``Boolean`` **default**: ``false``
564+
565+
If this option is enabled, the `egulias/email-validator`_ library will be
566+
used by the:doc:`/reference/constraints/Email` constraint validator. Otherwise,
567+
the validator uses a simple regular expression to validate email addresses.
568+
569+
api
570+
...
571+
572+
..versionadded::2.5
573+
The ``api`` option was introduced in Symfony 2.5.
574+
575+
**type**: ``string``
576+
577+
Starting with Symfony 2.5, the Validator component introduced a new validation
578+
API. The ``api`` option is used to switch between the different implementations:
579+
580+
``2.4``
581+
Use the vaidation API that is compatible with older Symfony versions.
582+
583+
``2.5``
584+
Use the validation API introduced in Symfony 2.5.
585+
586+
``2.5-bc`` or ``auto``
587+
If you omit a value or set the ``api`` option to ``2.5-bc`` or ``auto``,
588+
Symfony will use an API implementation that is compatible with both the
589+
legacy implementation and the ``2.5`` implementation. You have to use
590+
PHP 5.3.9 or higher to be able to use this implementation.
591+
555592
Full default Configuration
556593
--------------------------
557594

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp