PluginProbe
Formidable Forms – WordPress Form Builder for Contact Forms, Calculators, Quizzes & More / 4.01.02
Formidable Forms – WordPress Form Builder for Contact Forms, Calculators, Quizzes & More v4.01.02
6.35 6.34 6.33.1 6.33 6.32.1 6.32 6.31 6.25 6.25.1 6.26 6.26.1 6.27 6.28 6.29 6.3 6.3.1 6.3.2 6.30 6.4 6.4.1 6.4.2 6.5 6.5.1 6.5.2 6.5.3 All 141 releases
← All changes | classes/models/fields/FrmFieldText.php +0 -27 6.324.01.02 View file →
@@ -1,8 +1,5 @@
1 1 <?php
2 -if ( ! defined( 'ABSPATH' ) ) {
3 - die( 'You are not allowed to call this page directly.' );
4 -}
5 2
6 3 /**
7 4 * @since 3.0
8 5 */
@@ -9,9 +6,8 @@
9 6 class FrmFieldText extends FrmFieldType {
10 7
11 8 /**
12 9 * @var string
13 - *
14 10 * @since 3.0
15 11 */
16 12 protected $type = 'text';
17 13
@@ -16,21 +12,12 @@
16 12 protected $type = 'text';
17 13
18 14 /**
19 15 * @var bool
20 - *
21 16 * @since 3.0
22 17 */
23 18 protected $holds_email_values = true;
24 19
25 - /**
26 - * @var bool
27 - */
28 - protected $array_allowed = false;
29 -
30 - /**
31 - * @return bool[]
32 - */
33 20 protected function field_settings_for_type() {
34 21 return array(
35 22 'size' => true,
36 23 'clear_on_focus' => true,
@@ -36,20 +23,6 @@
36 23 'clear_on_focus' => true,
37 24 'format' => true,
38 25 'invalid' => true,
39 26 );
40 - }
41 -
42 - /**
43 - * @param array $args
44 - */
45 - public function validate( $args ) {
46 - $errors = parent::validate( $args );
47 - $max_length = intval( FrmField::get_option( $this->field, 'max' ) );
48 -
49 - if ( $max_length && FrmAppHelper::mb_function( array( 'mb_strlen', 'strlen' ), array( $args['value'] ) ) > $max_length ) {
50 - $errors[ 'field' . $args['id'] ] = FrmFieldsHelper::get_error_msg( $this->field, 'invalid' );
51 - }
52 -
53 - return $errors;
54 27 }
55 28 }