/**
  * Returns Data Attribute Array for JS validation with parsley.js
  *
  * @param Field $field
  * @param array $additionalAttributes To add further attributes
  * @param mixed $iteration Iterationarray for Multi Fields (Radio, Check, ...)
  * @return array for data attributes
  */
 public function render(Field $field, $additionalAttributes = array(), $iteration = NULL)
 {
     $additionalAttributes = parent::render($field, $additionalAttributes);
     if ($this->isClientValidationEnabled()) {
         $additionalAttributes['data-parsley-equalto'] = '#powermail_field_' . $field->getMarker();
         $additionalAttributes['data-parsley-equalto-message'] = LocalizationUtility::translate('validationerror_password', $this->extensionName);
     }
     return $additionalAttributes;
 }
 /**
  * Returns Data Attribute Array for JS validation with parsley.js
  *
  * @param Field $field
  * @param array $additionalAttributes To add further attributes
  * @param mixed $iteration Iterationarray for Multi Fields (Radio, Check, ...)
  * @return array for data attributes
  */
 public function render(Field $field, $additionalAttributes = array(), $iteration = null)
 {
     if ($field->getType() !== 'captcha') {
         return $additionalAttributes;
     }
     $dataArray = parent::render($field, $additionalAttributes, $iteration);
     if ($this->isNativeValidationEnabled()) {
         $dataArray['required'] = 'required';
     } elseif ($this->isClientValidationEnabled()) {
         $dataArray['data-parsley-required'] = 'true';
     }
     if ($this->isClientValidationEnabled()) {
         $dataArray['data-parsley-errors-container'] = '.powermail_field_error_container_' . $field->getMarker();
         $dataArray['data-parsley-class-handler'] = '.powermail_fieldwrap_' . $field->getUid() . ' > div';
         $dataArray['data-parsley-required-message'] = LocalizationUtility::translate('validationerror_mandatory');
     }
     return $dataArray;
 }