| @@ -23,18 +23,14 @@ | ||
| 23 | 23 | |
| 24 | 24 | // let's not show the name field if user choose to auto populate for logged users |
| 25 | 25 | if ( isset( $field_settings['auto_populate'] ) && $field_settings['auto_populate'] == 'yes' && is_user_logged_in() ) { |
| 26 | 26 | return; |
| 27 | - } | |
| 28 | - $form_settings = weforms()->form->get( $form_id )->get_settings(); | |
| 29 | - | |
| 30 | - $use_theme_css = isset( $form_settings['use_theme_css'] ) ? $form_settings['use_theme_css'] : 'wpuf-style'; | |
| 31 | - ?> | |
| 27 | + } ?> | |
| 32 | 28 | <li <?php $this->print_list_attributes( $field_settings ); ?>> |
| 33 | 29 | <?php $this->print_label( $field_settings, $form_id ); ?> |
| 34 | 30 | |
| 35 | 31 | <div class="wpuf-fields"> |
| 36 | - <div class="wpuf-name-field-wrap format-<?php echo esc_attr( $field_settings['format'] ); ?>" data-style="<?php echo esc_attr( $use_theme_css ); ?>"> | |
| 32 | + <div class="wpuf-name-field-wrap format-<?php echo esc_attr( $field_settings['format'] ); ?>"> | |
| 37 | 33 | <div class="wpuf-name-field-first-name"> |
| 38 | 34 | <input |
| 39 | 35 | name="<?php echo esc_attr( $field_settings['name'] ) ?>[first]" |
| 40 | 36 | type="text" |
| @@ -42,14 +38,13 @@ | ||
| 42 | 38 | value="<?php echo esc_attr( $field_settings['first_name']['default'] ); ?>" |
| 43 | 39 | size="40" |
| 44 | 40 | data-required="<?php echo esc_attr( $field_settings['required'] ) ?>" |
| 45 | 41 | data-type="text" |
| 46 | - data-style="<?php echo esc_attr( $use_theme_css ); ?>" | |
| 47 | 42 | class="textfield wpuf_<?php echo esc_attr( $field_settings['name'] ); ?>_<?php echo esc_attr( $form_id); ?>" |
| 48 | 43 | autocomplete="given-name" |
| 49 | 44 | > |
| 50 | 45 | <?php if ( ! $field_settings['hide_subs'] ) : ?> |
| 51 | - <label class="wpuf-form-sub-label" data-style="<?php echo esc_attr( $use_theme_css ); ?>"><?php esc_html_e( 'First', 'weforms' ); ?></label> | |
| 46 | + <label class="wpuf-form-sub-label"><?php esc_html_e( 'First', 'weforms' ); ?></label> | |
| 52 | 47 | <?php endif; ?> |
| 53 | 48 | </div> |
| 54 | 49 | |
| 55 | 50 | <?php if ( $field_settings['format'] != 'first-last' ) { ?> |
| @@ -60,12 +55,11 @@ | ||
| 60 | 55 | placeholder="<?php echo esc_attr( $field_settings['middle_name']['placeholder'] ); ?>" |
| 61 | 56 | value="<?php echo esc_attr( $field_settings['middle_name']['default'] ); ?>" |
| 62 | 57 | size="40" |
| 63 | 58 | autocomplete="additional-name" |
| 64 | - data-style="<?php echo esc_attr( $use_theme_css ); ?>" | |
| 65 | 59 | > |
| 66 | 60 | <?php if ( ! $field_settings['hide_subs'] ) : ?> |
| 67 | - <label class="wpuf-form-sub-label" data-style="<?php echo esc_attr( $use_theme_css ); ?>"><?php esc_html_e( 'Middle', 'weforms' ); ?></label> | |
| 61 | + <label class="wpuf-form-sub-label"><?php esc_html_e( 'Middle', 'weforms' ); ?></label> | |
| 68 | 62 | <?php endif; ?> |
| 69 | 63 | </div> |
| 70 | 64 | <?php } else { ?> |
| 71 | 65 | <input type="hidden" name="<?php echo esc_attr( $field_settings['name'] ) ?>[middle]" value=""> |
| @@ -78,12 +72,11 @@ | ||
| 78 | 72 | placeholder="<?php echo esc_attr( $field_settings['last_name']['placeholder'] ); ?>" |
| 79 | 73 | value="<?php echo esc_attr( $field_settings['last_name']['default'] ); ?>" |
| 80 | 74 | size="40" |
| 81 | 75 | autocomplete="family-name" |
| 82 | - data-style="<?php echo esc_attr( $use_theme_css ); ?>" | |
| 83 | 76 | > |
| 84 | 77 | <?php if ( ! $field_settings['hide_subs'] ) : ?> |
| 85 | - <label class="wpuf-form-sub-label" data-style="<?php echo esc_attr( $use_theme_css ); ?>"><?php esc_html_e( 'Last', 'weforms' ); ?></label> | |
| 78 | + <label class="wpuf-form-sub-label"><?php esc_html_e( 'Last', 'weforms' ); ?></label> | |
| 86 | 79 | <?php endif; ?> |
| 87 | 80 | </div> |
| 88 | 81 | </div> |
| 89 | 82 | <?php $this->help_text( $field_settings ); ?> |