Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- /**
- * Fix for empty ID bug in WPForms
- */
- // This can be found around lines 423 - 428.
- $labelID = implode( ' ', $field_atts['label_id'] ); // added to a variable
- if ( $labelID ) { // checking if the ID is set
- $labelIDoutput = 'id="' . $labelID . '"'; // if so, wrap in attribute, else, don't output anything
- }
- echo '<label for="wpforms-' . absint( $form_data['id'] ) . '-field_' . absint( $field['id'] ) . '" class="' . implode( ' ', $field_atts['label_class'] ) . '"' . $labelIDoutput . '>';
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement