PluginProbe
Formidable Forms – WordPress Form Builder for Contact Forms, Calculators, Quizzes & More / 6.12
Formidable Forms – WordPress Form Builder for Contact Forms, Calculators, Quizzes & More v6.12
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/FrmFieldPhone.php +38 -9 6.36.12 View file →
@@ -14,13 +14,8 @@
14 14 */
15 15 protected $type = 'phone';
16 16
17 17 /**
18 - * @var string
19 - */
20 - protected $display_type = 'text';
21 -
22 - /**
23 18 * @var bool
24 19 * @since 3.0
25 20 */
26 21 protected $holds_email_values = true;
@@ -37,19 +32,53 @@
37 32 return array(
38 33 'size' => true,
39 34 'clear_on_focus' => true,
40 35 'invalid' => true,
41 - 'format' => true,
42 36 );
43 37 }
44 38
45 39 /**
40 + * @since 6.9
41 + *
42 + * @param array $args Includes 'field', 'display', and 'values'.
43 + *
44 + * @return void
45 + */
46 + public function show_primary_options( $args ) {
47 + $field = $args['field'];
48 +
49 + include FrmAppHelper::plugin_path() . '/classes/views/frm-fields/back-end/phone/phone-type.php';
50 + FrmFieldsController::show_format_option( $field );
51 +
52 + parent::show_primary_options( $args );
53 + }
54 +
55 + /**
56 + * Retrieves the HTML for an 'International' option in a dropdown.
57 + *
58 + * @since 6.9
59 + *
60 + * @return void Outputs the HTML option tag directly.
61 + */
62 + protected function print_international_option() {
63 + ?>
64 + <option
65 + value="international"
66 + class="frm_show_upgrade frm_noallow"
67 + data-upgrade="<?php esc_attr_e( 'International phone field', 'formidable' ); ?>"
68 + data-medium="international-phone-field"
69 + <?php selected( FrmField::get_option( $this->field, 'format' ), 'international' ); ?>
70 + >
71 + <?php esc_html_e( 'International', 'formidable' ); ?>
72 + </option>
73 + <?php
74 + }
75 +
76 + /**
46 77 * @return string
47 78 */
48 79 protected function html5_input_type() {
49 - $frm_settings = FrmAppHelper::get_settings();
50 -
51 - return $frm_settings->use_html ? 'tel' : 'text';
80 + return 'tel';
52 81 }
53 82
54 83 /**
55 84 * @since 4.0.04