Changeset 12875 for trunk/src/bp-members/screens/register.php
- Timestamp:
- 04/01/2021 08:42:37 AM (4 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/bp-members/screens/register.php
r12679 r12875 156 156 * 157 157 * @since 1.5.0 158 * 159 * @param string $value Error message wrapped in html. 158 * @since 8.0.0 Adds the `$fieldname` parameter to the anonymous function. 159 * 160 * @param string $value Error message wrapped in html. 161 * @param string $fieldname The name of the signup field. 160 162 */ 161 add_action( 'bp_' . $fieldname . '_errors', function() use ( $error_message ) { 162 echo apply_filters( 'bp_members_signup_error_message', "<div class=\"error\">" . $error_message . "</div>" ); 163 add_action( 'bp_' . $fieldname . '_errors', function() use ( $error_message, $fieldname ) { 164 /** 165 * Filter here to edit the error message about the invalid field value. 166 * 167 * @since 1.5.0 168 * @since 8.0.0 Adds the `$fieldname` parameter. 169 * 170 * @param string $value Error message wrapped in html. 171 * @param string $fieldname The name of the signup field. 172 */ 173 echo apply_filters( 'bp_members_signup_error_message', "<div class=\"error\">" . $error_message . "</div>", $fieldname ); 163 174 } ); 164 175 }
Note: See TracChangeset
for help on using the changeset viewer.