Billing address 2 label: double “optional” string
-
In WC v3.6.3, in the file woocommerce/includes/class-wc-countries.php, between lines 622-626 there is:
if ( 'optional' === get_option( 'woocommerce_checkout_address_2_field', 'optional' ) ) { $address_2_placeholder = __( 'Apartment, suite, unit etc.', 'woocommerce' ); } else { $address_2_placeholder = __( 'Apartment, suite, unit etc.', 'woocommerce' ); }
The result is a double “optional” string in the label when the field is not required. Something like:
Apartment, suite, unit etc. (optional) (optional)
The second “(optional)” string comes from a span tag:
<span class="optional">(optional)</span>
added to not required fields.
Why there is the if statement in the class-wc-countries.php file?
Viewing 4 replies - 1 through 4 (of 4 total)
Viewing 4 replies - 1 through 4 (of 4 total)
- The topic ‘Billing address 2 label: double “optional” string’ is closed to new replies.