PluginProbe
Formidable Forms – WordPress Form Builder for Contact Forms, Calculators, Quizzes & More / 4.02.04
Formidable Forms – WordPress Form Builder for Contact Forms, Calculators, Quizzes & More v4.02.04
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
formidable / classes / models / fields / FrmFieldRadio.php

FrmFieldRadio.php in Formidable Forms – WordPress Form Builder for Contact Forms, Calculators, Quizzes & More 4.02.04, at classes/models/fields/FrmFieldRadio.php

75 lines 1.3 KB
No matching file
Up and down to move Enter to open Esc to close
Raw Download Zip
1 <?php
2
3 /**
4 * @since 3.0
5 */
6 class FrmFieldRadio extends FrmFieldType {
7
8 /**
9 * @var string
10 * @since 3.0
11 */
12 protected $type = 'radio';
13
14 /**
15 * @var bool
16 * @since 3.0
17 */
18 protected $holds_email_values = true;
19
20 /**
21 * Does the html for this field label need to include "for"?
22 *
23 * @var bool
24 * @since 3.06.01
25 */
26 protected $has_for_label = false;
27
28 protected function input_html() {
29 return $this->multiple_input_html();
30 }
31
32 protected function include_form_builder_file() {
33 return $this->include_front_form_file();
34 }
35
36 /**
37 * Get the type of field being displayed.
38 *
39 * @since 4.02.01
40 * @return array
41 */
42 public function displayed_field_type( $field ) {
43 return array(
44 $this->type => true,
45 );
46 }
47
48 protected function extra_field_opts() {
49 $form_id = $this->get_field_column( 'form_id' );
50
51 return array(
52 'align' => FrmStylesController::get_style_val( 'radio_align', ( empty( $form_id ) ? 'default' : $form_id ) ),
53 );
54 }
55
56 protected function new_field_settings() {
57 return array(
58 'options' => serialize(
59 array(
60 __( 'Option 1', 'formidable' ),
61 __( 'Option 2', 'formidable' ),
62 )
63 ),
64 );
65 }
66
67 protected function include_front_form_file() {
68 return FrmAppHelper::plugin_path() . '/classes/views/frm-fields/front-end/radio-field.php';
69 }
70
71 protected function show_readonly_hidden() {
72 return true;
73 }
74 }
75