PluginProbe
Formidable Forms – WordPress Form Builder for Contact Forms, Calculators, Quizzes & More / 5.0
Formidable Forms – WordPress Form Builder for Contact Forms, Calculators, Quizzes & More v5.0
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/FrmFieldValue.php +3 -28 6.35.0 View file →
@@ -61,25 +61,13 @@
61 61 $this->init_saved_value( $entry );
62 62 }
63 63
64 64 /**
65 - * Gets entry property.
66 - *
67 - * @since 5.0.16
68 - * @return stdClass
69 - */
70 - public function get_entry() {
71 - return $this->entry;
72 - }
73 -
74 - /**
75 65 * Initialize the saved_value property
76 66 *
77 67 * @since 2.04
78 68 *
79 69 * @param stdClass $entry
80 - *
81 - * @return void
82 70 */
83 71 protected function init_saved_value( $entry ) {
84 72 if ( $this->field->type === 'html' ) {
85 73 $this->saved_value = $this->field->description;
@@ -97,10 +85,8 @@
97 85 *
98 86 * @since 2.05
99 87 *
100 88 * @param array $atts
101 - *
102 - * @return void
103 89 */
104 90 public function prepare_displayed_value( $atts = array() ) {
105 91 $this->displayed_value = $this->saved_value;
106 92 unset( $atts['class'] ); // This class shouldn't affect values.
@@ -111,10 +97,8 @@
111 97 /**
112 98 * Get a value from the field settings
113 99 *
114 100 * @since 2.05.06
115 - *
116 - * @param string $value
117 101 */
118 102 public function get_field_option( $value ) {
119 103 return FrmField::get_option( $this->field, $value );
120 104 }
@@ -120,10 +104,8 @@
120 104 }
121 105
122 106 /**
123 107 * @since 4.03
124 - *
125 - * @param string $option
126 108 */
127 109 public function get_field_attr( $option ) {
128 110 return is_object( $this->field ) ? $this->field->{$option} : '';
129 111 }
@@ -129,10 +111,8 @@
129 111 }
130 112
131 113 /**
132 114 * @since 4.03
133 - *
134 - * @return stdClass
135 115 */
136 116 public function get_field() {
137 117 return $this->field;
138 118 }
@@ -201,9 +181,9 @@
201 181 * @since 3.0
202 182 *
203 183 * @param array $atts
204 184 *
205 - * @return void
185 + * @return mixed
206 186 */
207 187 protected function generate_displayed_value_for_field_type( $atts ) {
208 188 if ( ! FrmAppHelper::is_empty_value( $this->displayed_value, '' ) ) {
209 189 $field_obj = FrmFieldFactory::get_field_object( $this->field );
@@ -217,10 +197,8 @@
217 197 *
218 198 * @since 2.04
219 199 *
220 200 * @param array $atts
221 - *
222 - * @return void
223 201 */
224 202 protected function filter_displayed_value( $atts ) {
225 203 if ( ! is_object( $this->entry ) || empty( $this->entry->metas ) ) {
226 204 $this->entry = FrmEntry::getOne( $this->entry_id, true );
@@ -266,19 +244,16 @@
266 244 $this->displayed_value = apply_filters( 'frm_display_value', $this->displayed_value, $this->field, $atts );
267 245 }
268 246
269 247 /**
270 - * Clean a field's saved value.
248 + * Clean a field's saved value
271 249 *
272 250 * @since 2.04
273 - *
274 - * @return void
275 251 */
276 252 protected function clean_saved_value() {
277 253 if ( $this->saved_value !== '' ) {
278 254 if ( ! is_array( $this->saved_value ) && ! is_object( $this->saved_value ) ) {
279 - $field_type = FrmField::get_field_type( $this->field );
280 - FrmFieldsHelper::prepare_field_value( $this->saved_value, $field_type );
255 + FrmAppHelper::unserialize_or_decode( $this->saved_value );
281 256 }
282 257
283 258 if ( is_array( $this->saved_value ) && empty( $this->saved_value ) ) {
284 259 $this->saved_value = '';