Opened 9 years ago
Closed 9 years ago
#6575 closed enhancement (fixed)
Make the (required) portion of the Xprofile field label filterable
Reported by: | garrett-eclipse | Owned by: | dcavins |
---|---|---|---|
Milestone: | 2.4 | Priority: | normal |
Severity: | normal | Version: | 2.3.2 |
Component: | Extended Profile | Keywords: | dev-feedback |
Cc: |
Description
Hello,
Full details on my support request - https://buddypress.org/support/topic/feature-request-filterable-xprofile-field-labels/#post-242779
In short I'd like the '(required)' text of the Xprofile field label to be filterable so it can be replaced where appropriate. In my case I'd like to replace it when the field is implemented on the Woocommerce checkout page so the denotation of required matches the Woocommerce fields.
Code to Amend;
<label for="<?php bp_the_profile_field_input_name(); ?>"> <?php bp_the_profile_field_name(); ?> <?php if ( bp_get_the_profile_field_is_required() ) : ?> <?php esc_html_e( '(required)', 'buddypress' ); ?> <?php endif; ?> </label>
Suggested fix could either be implementing the filter here directly or by setting up a function bp_the_profile_field_input_required() which implements the filter.
Thank you
P.S. A current js workaround is posted on the original support ticket.
I'd like to fix this at the same time as #6521. See that ticket for my suggested fix.