PluginProbe
Formidable Forms – WordPress Form Builder for Contact Forms, Calculators, Quizzes & More / trunk
Formidable Forms – WordPress Form Builder for Contact Forms, Calculators, Quizzes & More vtrunk
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/FrmFieldName.php +5 -8 6.29 → trunk View file →
@@ -60,12 +60,11 @@
60 60 *
61 61 * @return array
62 62 */
63 63 protected function get_processed_sub_fields() {
64 - $name_layout = $this->get_name_layout();
65 - $names = explode( '_', $name_layout );
66 - $col_class = 'frm' . intval( 12 / count( $names ) );
67 - $result = array();
64 + $names = explode( '_', $this->get_name_layout() );
65 + $col_class = 'frm' . intval( 12 / count( $names ) );
66 + $result = array();
68 67
69 68 foreach ( $names as $name ) {
70 69 if ( empty( $this->sub_fields[ $name ] ) ) {
71 70 continue;
@@ -146,10 +145,8 @@
146 145 if ( ! empty( $atts['show'] ) ) {
147 146 return $value[ $atts['show'] ] ?? '';
148 147 }
149 148
150 - $name_layout = $this->get_name_layout();
151 -
152 149 $value = wp_parse_args(
153 150 $value,
154 151 array(
155 152 'first' => '',
@@ -157,9 +154,9 @@
157 154 'last' => '',
158 155 )
159 156 );
160 157
161 - switch ( $name_layout ) {
158 + switch ( $this->get_name_layout() ) {
162 159 case 'last_first':
163 160 $value = $value['last'] . ' ' . $value['first'];
164 161 break;
165 162
@@ -247,9 +244,9 @@
247 244 * Gets inputs container attributes.
248 245 *
249 246 * @return array
250 247 */
251 - protected function get_inputs_container_attrs() {
248 + public function get_inputs_container_attrs() {
252 249 $attrs = parent::get_inputs_container_attrs();
253 250
254 251 $attrs['data-name-layout'] = $this->get_name_layout();
255 252 return $attrs;