Submit
Path:
~
/
/
opt
/
cloudlinux
/
alt-php53
/
root
/
usr
/
share
/
pear
/
Symfony
/
Component
/
Form
/
Extension
/
Validator
/
Type
/
File Content:
RepeatedTypeValidatorExtension.php
<?php /* * This file is part of the Symfony package. * * (c) Fabien Potencier <fabien@symfony.com> * * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ namespace Symfony\Component\Form\Extension\Validator\Type; use Symfony\Component\Form\AbstractTypeExtension; use Symfony\Component\OptionsResolver\Options; use Symfony\Component\OptionsResolver\OptionsResolverInterface; /** * @author Bernhard Schussek <bschussek@gmail.com> */ class RepeatedTypeValidatorExtension extends AbstractTypeExtension { /** * {@inheritdoc} */ public function setDefaultOptions(OptionsResolverInterface $resolver) { // Map errors to the first field $errorMapping = function (Options $options) { return array('.' => $options['first_name']); }; $resolver->setDefaults(array( 'error_mapping' => $errorMapping, )); } /** * {@inheritdoc} */ public function getExtendedType() { return 'repeated'; } }
Submit
FILE
FOLDER
Name
Size
Permission
Action
BaseValidatorExtension.php
1489 bytes
0644
FormTypeValidatorExtension.php
2520 bytes
0644
RepeatedTypeValidatorExtension.php
1088 bytes
0644
SubmitTypeValidatorExtension.php
539 bytes
0644
N4ST4R_ID | Naxtarrr