Action uncanny-learndash-groups

ulgm_groups_registration_form_before_password_confirm

Fires just before the password confirmation field is displayed on the group registration form.

add_action( 'ulgm_groups_registration_form_before_password_confirm', $callback, 10, 1 );

Description

Fires just before the password confirmation field on the Uncanny Groups registration form. Developers can use this hook to add custom fields, validation logic, or modify the appearance of the form before the password confirmation input.


Usage

add_action( 'ulgm_groups_registration_form_before_password_confirm', 'your_function_name', 10, 1 );

Examples

add_action( 'ulgm_groups_registration_form_before_password_confirm', 'my_custom_password_confirm_field', 10, 0 );

/**
 * Adds a custom security question field before the password confirmation field.
 * This is just an example to demonstrate adding custom fields.
 *
 * @since 1.0.0
 */
function my_custom_password_confirm_field() {
	?>
	<!-- Custom Security Question START -->
	<tr>
		<td class="label"><label for="security_question"><?php esc_html_e( 'What is your favorite color?', 'my-custom-plugin' ); ?></label>
		</td>
		<td class="input">
			<input type="text" name="ulgm_security_question" id="security_question" class="required" placeholder="<?php esc_html_e( 'Your favorite color', 'my-custom-plugin' ); ?>" />
		</td>
	</tr>
	<!-- Custom Security Question END -->
	<?php
}

Placement

This code should be placed in the functions.php file of your active theme, a custom plugin, or using a code snippets plugin.


Source Code

src/includes/forms/user-registration-form.php:88

minlength="6"
							   class="required"
							   placeholder="<?php esc_html_e( 'Password', 'uncanny-learndash-groups' ); ?>"
							   type="password"/></td>
				</tr>
				<!-- Password __ END -->
				<?php do_action( 'ulgm_groups_registration_form_after_password' ); ?>
				<?php do_action( 'ulgm_groups_registration_form_before_password_confirm' ); ?>
				<!-- Confirm Password  __ START -->
				<tr>
					<td class="label"><label
								for="password_again"><?php esc_html_e( 'Confirm Password', 'uncanny-learndash-groups' ); ?></label>
					</td>
					<td class="input">
						<input name="ulgm_user_pass_confirm" id="password_again"


Scroll to Top