I'm using a View with radio controls to filter results with "AJAX results update when visitors change any filter values"
Display options
Type of control - Set of radio buttons
This is part of the filtered view:
[wpv-control-postmeta field="wpcf-accreditation-class" type="radios" default_label="All" url_param="wpv-wpcf-accreditation-class"]
Unfortunately the outputted code wraps the radio elements within the label, eg:
<label><input>Label</label>
This is the source output
<div class="radio">
<label for="form-XXX"><input type="radio" class="js-wpv-filter-trigger" name="wpv-wpcf-accreditation-class" value="Product" id="form-XXX">Product
</label>
</div>
It should be
<input><label>Label</label>
For example:
<div class="radio">
<input type="radio" class="js-wpv-filter-trigger" name="wpv-wpcf-accreditation-class" value="Product" id="form-XXX">
<label for="form-XXX">Product</label>
</div>
Could you get this looked into and updated ASAP please?
The relevant function is
found at:
\wp-content\plugins\wp-views\embedded\inc\walkers\wpv_walker_postmeta_radios.class.php
NB: The reason this is important is that I'm replacing the standard radio elements using
with the DIVI's "ETmodules" font which includes larger icons for form elements.
I can't hide the
and insert a circular font glyph to replace the radio buttons as the CSS Pseudo-classes
only works on a radio element.
In the interim, if you know how to adjust the function to display the input before the label (see below) I can adjust the wpv_walker_postmeta_radios.class to get this working for the deadline and be very grateful!
$output .= '<div class="radio">';
$input_output = $this->el_input( $args['attributes']['input'] );
$output .= $this->el_label( $input_output . $args['label'], $args['attributes']['label'] );
$output .= '</div>';