Customized registration method and compatibility with WP user manager plugin
-
Hello,
I am using the plugin WP User Manager for registration and it uses its own customized registration method. I have found exactly here that there is a hook with filter in the registration form of the plugin.
So from your example i have tried to do something like this:
add_action('init', 'mydomain_plugin_checks'); function mydomain_plugin_checks(){ if ( class_exists('BanHammer') ) { add_filter( 'wpum/form/validate=register', 'wpum_verify_email_domain', 10, 2 ); } } function wpum_verify_email_domain( $passed, $values ) { $email_domain = $values['register'][ 'user_email' ]; if( (new BanHammer)->banhammer_drop($email_domain) ) { return new WP_Error( 'email-validation-error', (new BanHammer)->options['message'] ); } return $passed; }
But yet it doesn’t work (breaks the page or just don’t uses your IF check, when submitting the registration form. ) ??
I am not so good with .php, so if you can help me out with this i would really appreciate. Maybe to suggest some code.
I have tested your plugin in general and rocks!
Best regards.
Viewing 7 replies - 1 through 7 (of 7 total)
Viewing 7 replies - 1 through 7 (of 7 total)
- The topic ‘Customized registration method and compatibility with WP user manager plugin’ is closed to new replies.